seong

백준 11022번 본문

알고리즘/백준

백준 11022번

hyeonseong 2022. 7. 29. 10:27
import java.io.*;
import java.nio.Buffer;
import java.util.Scanner;
import java.util.StringTokenizer;

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 n = Integer.parseInt(br.readLine());
        int a;
        int b;
        StringTokenizer number;
        for(int i = 1; i <= n; i ++){
            number = new StringTokenizer(br.readLine()," ");
            a = Integer.parseInt(number.nextToken());
            b = Integer.parseInt(number.nextToken());
            bw.write("Case #" + i + ": " + a + " + "+ b + " = ");
            bw.write(a+b + "\n");

        }
        br.close();
        bw.flush();
        bw.close();

    }
}

'알고리즘 > 백준' 카테고리의 다른 글

백준 2439번  (0) 2022.07.29
백준 2438번  (0) 2022.07.29
백준 11021번  (0) 2022.07.29
백준 2742번  (0) 2022.07.29
백준 10952번  (0) 2022.07.29