2017年11月9日

摘要: #include using namespace std; int m(int x,int y,int z); short m(short q,short w,short e); double m(double a,double s,double d); int main(){ int a,b,c,min; cin>>a>>b>>c; min=m(a,b,c); ... 阅读全文
posted @ 2017-11-09 20:41 三叶癌 阅读(110) 评论(0) 推荐(0) 编辑
摘要: #include using namespace std; int m(int x,int y,int z); int main(){ int a,b,c,max; cin>>a>>b>>c; max=m(a,b,c); coutx) x=z; if(y>x) x=y; return x; } ... 阅读全文
posted @ 2017-11-09 20:19 三叶癌 阅读(78) 评论(0) 推荐(0) 编辑

2017年11月6日

摘要: #include using namespace std; int jc(int num){ int a; if(num==1) a=1; else a=jc(num-1)*num; return a; } int main(){ int b=8; cout<<jc(8)<<endl; return 0; } 阅读全文
posted @ 2017-11-06 22:26 三叶癌 阅读(129) 评论(0) 推荐(0) 编辑
摘要: #include using namespace std; int age(int num){ int a; if(num==1) a=10; else a=age(num-1)+2; return a; } int main(){ cout<<age(5)<<endl; return 0; } 阅读全文
posted @ 2017-11-06 22:22 三叶癌 阅读(89) 评论(0) 推荐(0) 编辑
摘要: #include using namespace std; int main(){ int a,b,c,d,max; cout>a>>b>>c>>d; max=a>=b?a:b; max=max>=c?max:c; max=max>=d?max:d; cout using namespace std; int max2(int p,int o,i... 阅读全文
posted @ 2017-11-06 22:19 三叶癌 阅读(94) 评论(0) 推荐(0) 编辑
摘要: #include using namespace std; int sum(int x,int y); int main(){ int a,b,s; cout>a>>b; s=sum(a,b); cout<<"the sum of a and b"<<s<<endl; return 0; } int sum(int x,int y){ ... 阅读全文
posted @ 2017-11-06 21:38 三叶癌 阅读(77) 评论(0) 推荐(0) 编辑

2017年10月20日

摘要: #include using namespace std; int main(){ cout>num1>>num2; int Max(int x,int y); num1=Max(num1,num2); couty?x:y; } 阅读全文
posted @ 2017-10-20 10:58 三叶癌 阅读(65) 评论(0) 推荐(0) 编辑

2017年10月19日

摘要: #include using namespace std; int main(){ int y; cout>y; if(y%4==0){ if(100%y==0){ if(y%400==0){ cout<<"zhe shi run nian"; ... 阅读全文
posted @ 2017-10-19 15:48 三叶癌 阅读(87) 评论(0) 推荐(0) 编辑
摘要: #include #include #include using namespace std; int main(){ int a,b,c,s; cout>a>>b>>c; if(a+b>c&&a+c>b&&b+c>a){ s=(a+b+c)/2; cout<<s<<endl; }else{ cout<<"it is no... 阅读全文
posted @ 2017-10-19 14:56 三叶癌 阅读(101) 评论(0) 推荐(0) 编辑
摘要: #include #include using namespace std; int main(){ double a=147.369,b=3.46168,c=-4572.67; cout<<setiosflags(ios::fixed)<<setiosflags(ios::right)<<setprecision(3); cout<<setw(10)... 阅读全文
posted @ 2017-10-19 14:32 三叶癌 阅读(75) 评论(0) 推荐(0) 编辑

导航