题目描述
你的任务是计算a+b。这是为了acm初学者专门设计的题目。你肯定发现还有其他题目跟这道题的标题类似,这些问题也都是专门为初学者提供的。
输入
输入包含一系列的a和b对,通过空格隔开。一对a和b占一行。
输出
每输入一对a和b,需要立刻输出a与b的和。
样例输入
1 5
10 20
样例输出
6
30
package test;
import java.util.Scanner;
public class Main {
/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
Scanner sc= new Scanner(System.in);
while(sc.hasNext())
{
int a = sc.nextInt();
int b = sc.nextInt();
System.out.println(a+b);
}
}
}