두 정수 A와 B를 입력받은 다음, A+B를 출력하는 프로그램을 작성하시오.
5
1 1
2 3
3 4
9 8
5 2
Case #1: 1 + 1 = 2
Case #2: 2 + 3 = 5
Case #3: 3 + 4 = 7
Case #4: 9 + 8 = 17
Case #5: 5 + 2 = 7
import java.io.*;
import java.util.StringTokenizer;
public class Main {
public static void main(String[] args) throws IOException{
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(System.out));
int a, b;
int t = Integer.parseInt(br.readLine());
for(int i=1; i<=t; i++) {
StringTokenizer st = new StringTokenizer(br.readLine());
a = Integer.parseInt(st.nextToken());
b = Integer.parseInt(st.nextToken());
bw.write("Case #" + i + ": " + a + " + " + b + " = " + (a+b) + "\n");
}
bw.flush();
bw.close();
}
}