标签:3.2 creat 没有 eoj system.in ati div col ems
12345678900
98765432100
1219326311126352690000
分析:
使用Java的BigInteger类来解决
核心代码:
1 a = sc.nextBigInteger(); 2 b = sc.nextBigInteger(); 3 System.out.println(a.nultiplt(b));
Java代码实现(AC):
1 import java.math.BigInteger; 2 import java.util.Scanner; 3 4 5 public class Main{ 6 public static void main(String args[]) { 7 Scanner sc = new Scanner(System.in); 8 BigInteger a, b; 9 a = sc.nextBigInteger(); 10 b = sc.nextBigInteger(); 11 System.out.println(a.multiply(b)); 12 } 13 }
suseoj 1207: 大整数的乘法(java, 大数相乘)
标签:3.2 creat 没有 eoj system.in ati div col ems
原文地址:https://www.cnblogs.com/GetcharZp/p/9054709.html