Calculate A + B.
Input
Each line will contain two integers A and B. Process to end of file.
Output
For each case, output A + B in one line.
Sample Input
1 1
Sample Output
2
多个数据输入,求和
换行输出
#include<stdio.h>
int main()
{
int A, B,C;
while (~scanf("%d%d", &A, &B))
{
C = A + B;
printf("%d\n", C);
}
}
网友评论