본문 바로가기
코딩테스트/백준

Java - 백준 코딩테스트 2839번 [기본수학1단계 - 큰 수 A+B]

by sycareer 2021. 8. 9.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import java.io.IOException;
import java.math.BigInteger;
import java.util.Scanner;
 
public class BigAplusB {
 
    public static void main(String[] args) throws IOException {
        // 20210809 - 백준 10757번
        Scanner sc = new Scanner(System.in);
        
        BigInteger a = sc.nextBigInteger();
        BigInteger b = sc.nextBigInteger();
        
        BigInteger result = a.add(b);
        
        System.out.println(result);
    }
 
}
 
cs