码迷,mamicode.com
首页 >  
搜索关键字:int-max    ( 1549个结果
2014华为编程比赛-筷子问题
//华为编程:筷子,找到第一个单对的筷子#include #define max 37int main(){ int n,i,j; int a[max]; int flag=0; int error=-1; scanf("%d",&n); if(n>max) ...
分类:其他好文   时间:2014-07-22 23:13:33    阅读次数:339
2014华为编程比赛-筷子问题
//华为编程:筷子,找到第一个单对的筷子#include #define max 37int main(){ int n,i,j; int a[max]; int flag=0; int error=-1; scanf("%d",&n); if(n>max) { printf("...
分类:其他好文   时间:2014-07-22 23:12:15    阅读次数:325
hdu 1003
题意 :求最大子段和 并且输出起始位置#includeusing namespace std;int main(){int N,n,a[100001],first,last; cin>>N; for(int i=1;i>n; for(int j=1;j>a[j]; int max=-...
分类:其他好文   时间:2014-05-06 00:12:25    阅读次数:301
hdu 1087 最大上升子序列和
题意:求最大上升子序列和#includeusing namespace std;int main(){ int n,a[1001],b[1001],max; while(cin>>n&&n!=0) { for(int i=1;i>a[i]; b[1]=a...
分类:其他好文   时间:2014-05-03 22:29:38    阅读次数:282
poj 3384 Feng Shui 半平面交的应用 求最多覆盖凸多边形的面积的两个圆 的圆心坐标
题目来源:http://poj.org/problem?id=3384分析:用半平面交将多边形的每条边一起向“内”推进R,得到新的多边形(半平面交),然后求多边形的最远两点。代码如下:const double EPS = 1e-10;const int Max_N = 105 ;struct Poi...
分类:其他好文   时间:2014-05-01 14:35:31    阅读次数:528
hdu 1233 还是畅通工程
简单最小生成树,继续我的kruskal#include#include#include#includeusing namespace std;const int MAX=1000000;struct node{ int left,right,cost;}road[MAX];bool cmp(n...
分类:其他好文   时间:2014-05-01 09:28:42    阅读次数:333
半平面交 模板 poj 3335 poj 3130 poj 1474 判断半平面交是否为空集
半平面交模板const double pi= acos(-1.0);#define arc(x) (x / 180 * pi)const double EPS = 1e-8;const int Max_N = 105;struct Point{ double x,y; Point(){}...
分类:其他好文   时间:2014-04-30 17:00:01    阅读次数:621
设置和获取Android中各种音量
通过程序获取android系统手机的铃声和音量。同样,设置铃声和音量的方法也很简单!AudioManager am = (AudioManager) getSystemService(Context.AUDIO_SERVICE);//通话音量 int max = am.getStreamMaxVol...
分类:移动开发   时间:2014-04-30 02:26:46    阅读次数:586
poj 1279 求半平面交的 面积
poj 1279 求半平面交的 面积题目来源:http://poj.org/problem?id=1279分析: 求半平面交的 面积代码如下:const double EPS = 1e-8;const int Max_N = 1505;struct Point{ double x,y; ...
分类:其他好文   时间:2014-04-29 16:35:46    阅读次数:499
1549条   上一页 1 ... 153 154 155
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!