1. 程式人生 > >java多組輸入

java多組輸入

import java.util.Scanner;
public class test {
public static void main(String[] args) {
int a, b;
Scanner reader = new Scanner(System.in);
while(reader.hasNext()){
a = reader.nextInt();
b = reader.nextInt();
System.out.println(a+b);
}


reader.close();
}
}