题解 | #高精度整数加法#

高精度整数加法

https://www.nowcoder.com/practice/49e772ab08994a96980f9618892e55b6

import java.util.*;
import java.math.BigInteger;

public class Main {
    public static void main(String[] args) {
        Scanner fzhinput = new Scanner(System.in);
        String zfc1 = fzhinput.nextLine();
        String zfc2 = fzhinput.nextLine();
        BigInteger sz1= new BigInteger(zfc1);
        BigInteger sz2= new BigInteger(zfc2);
        System.out.println(sz1.add(sz2));
    }
}

全部评论

相关推荐

评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务