백준 java 11022 A+B-8

임명수·2023년 5월 5일
0

백준

목록 보기
8/31

https://www.acmicpc.net/problem/11022


import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class Main{
    public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

        int A = Integer.parseInt(br.readLine());

        StringTokenizer st;
        for(int i =1; i<A+1; i++){
            st = new StringTokenizer(br.readLine(), " ");

            int a =Integer.parseInt(st.nextToken());
            int b =Integer.parseInt(st.nextToken());
            int c =a+b;
            System.out.println("Case #" + i + ": " + a + " + " + b + " = " +  c   );


        }
        br.close();
    }
}코드를 입력하세요
profile
푸른영혼의별

0개의 댓글