首页 > 代码库 > Java A+B(个人模版)

Java A+B(个人模版)

Java A+B:

 1 import java.io.*;
 2 import java.util.*;
 3 import java.math.BigInteger;
 4 import java.util.Scanner;
 5 public class Main
 6 {
 7     public static void main(String args[]) throws Exception
 8     {
 9         Scanner in = new Scanner(System.in);
10         while(in.hasNext())
11         {
12             BigInteger a, b;
13             a = in.nextBigInteger();
14             b = in.nextBigInteger();
15             System.out.println(a.add(b));
16         }
17     }
18 }

 

Java A+B(个人模版)