#include<iostream>using namespace std;int main(){ int n; while(cin>>n){ int sum=0; int i,m; for(i=1;i<=n;++i){ cin...
#include <iostream> #include <cstring> using namespace std; int n[3],a[9000],b[9000],i,j,k,last,last2; int v[3]={1,2,5}; int main() { while ((c...
#include <stdio.h> #include <string.h> int main() { int d[1001], ans[1001]; int n, i, j, flag, rst; while(~scanf("%d", &n) && n) { ...
#include <stdio.h> #include <string.h> int main() { char s[10000]; int len; int cnt = 0; while(~scanf("%s",s)) { ...
#include<iostream> using namespace std; int main() { int n,m,s; while(cin>>n>>m) { s=n+m; cout<<s<<endl; } return 0; }
#include<stdio.h>int main(){ int a,b; while(scanf("%d%d",&a,&b)==2) { if(a==0&&b==0) break; else printf("%dn",a+b); ...
#include <iostream> using namespace std; int main() { int n,a,sum=0; while(cin>>n&&n!=0) { while (n--) { ci...
#include <iostream> using namespace std; int main() { int n,m,a,sum=0; while(cin>>n) { while (n--) { ci...
#include <stdio.h> #include <string.h> #define MAXN 120005 int main() { int num[7]; int T = 0; while (scanf("%d %d %d %d %d %d", &num...
#include<iostream> #include<cmath> using namespace std; int main() { int T,t=0,m,n; cin>>T; while(T--) { cin>>m>>n;...