#include <stdio.h>
#include <iostream>
using namespace std;
int main(int argc, char *argv[]) {
int N;
cin>>N;
while(N)
{
int n;
while(cin>>n)
{
if(n == 0)break;
int sum = 0;
while(n)
{
int temp;
cin>>temp;
sum += temp;
n--;
}
printf("%d\n",sum);
}
N--;
}
return 0;
}
HDOJ1093
最新推荐文章于 2017-12-16 22:21:37 发布