2013年5月2日

HDOJ 1094 A+B for Input-Output Practice (VI)

摘要: http://acm.hdu.edu.cn/showproblem.php?pid=1094acm常见的输入输出类型,就是一种模板,花一点点时间背下来就可以了, 1 #include<iostream> 2 #include<stdio.h> 3 using namespace std; 4 int main (){ 5 int a,n; 6 while(scanf("%d",&n)!=EOF){ 7 int sum=0; 8 for(int i=0;i<n;i++){ 9 cin>>a;10 su... 阅读全文

posted @ 2013-05-02 09:50 wsxjbcy 阅读(113) 评论(0) 推荐(0) 编辑

HDOJ 1093 A+B for Input-Output Practice (V)

摘要: http://acm.hdu.edu.cn/showproblem.php?pid=1093acm常见的输入输出类型,就是一种模板,花一点点时间背下来就可以了,#include<iostream>using namespace std;int main (){ int a,n,m; cin>>m; for(int j=0;j<m;j++){ int sum=0; cin>>n; for(int i=0;i<n;i++){ cin>>a; sum+=a; } cou... 阅读全文

posted @ 2013-05-02 09:46 wsxjbcy 阅读(140) 评论(0) 推荐(0) 编辑

HDOJ 1092 A+B for Input-Output Practice (IV)

摘要: http://acm.hdu.edu.cn/showproblem.php?pid=1092acm常见的输入输出类型,就是一种模板,花一点点时间背下来就可以了, 1 #include<iostream> 2 using namespace std; 3 4 int main (){ 5 int a,n; 6 for(;;){ 7 int sum=0; 8 cin>>n; 9 if(n==0)10 break;11 for(int i=0;i<n;i++){12 cin>>a... 阅读全文

posted @ 2013-05-02 09:44 wsxjbcy 阅读(122) 评论(0) 推荐(0) 编辑

HDOJ 1091 A+B for Input-Output Practice (III)

摘要: http://acm.hdu.edu.cn/showproblem.php?pid=1091acm常见的输入输出类型,就是一种模板,花一点点时间背下来就可以了, 1 #include<iostream> 2 using namespace std; 3 int main (){ 4 int a,b; 5 while(true){ 6 cin>>a>>b; 7 if(a==0 && b==0) 8 break; 9 cout<<a+b<<endl;10 }11 return 0;12 } 阅读全文

posted @ 2013-05-02 09:42 wsxjbcy 阅读(165) 评论(0) 推荐(0) 编辑

HDOJ 1090 A+B for Input-Output Practice (II)

摘要: http://acm.hdu.edu.cn/showproblem.php?pid=1090acm常见的输入输出类型,就是一种模板,花一点点时间背下来就可以了, 1 #include<iostream> 2 using namespace std; 3 int main (){ 4 5 int a,b,n,i=0; 6 cin>>n; 7 while(i<n){ 8 cin>>a>>b; 9 cout<<a+b<<endl;10 i++;11 }12 return 0;13 } 阅读全文

posted @ 2013-05-02 09:39 wsxjbcy 阅读(123) 评论(0) 推荐(0) 编辑

HDOJ 1089 A+B for Input-Output Practice (I)

摘要: http://acm.hdu.edu.cn/showproblem.php?pid=1089acm常见的输入输出类型,就是一种模板,花一点点时间背下来就可以了,1 #include<iostream>2 using namespace std;3 int main (){4 int a,b;5 while(cin>>a>>b)6 cout<<a+b<<endl;7 return 0;8 } 阅读全文

posted @ 2013-05-02 09:32 wsxjbcy 阅读(97) 评论(0) 推荐(0) 编辑

导航