第1行:大数A
第2行:大数B
(A,B的长度 <= 100000,A,B >= 0)
输出A * B
123456
234567
28958703552
import java.math.BigInteger; import java.util.Scanner; public class Main{ public static void main(String[] args){ Scanner in = new Scanner(System.in); BigInteger a,b; a = in.nextBigInteger(); b = in.nextBigInteger(); System.out.println(a.multiply(b)); } }
原文:https://www.cnblogs.com/DWVictor/p/10507291.html