java大数类,两个不超过20位都不为0的十进制字符串相乘,华为笔试题
import java.math.BigInteger; import java.util.*; import java.io.*; public class Main { public static void main(String args[]) { Scanner in=new Scanner(System.in); BigInteger a=in.nextBigInteger(); BigInteger b=in.nextBigInteger(); BigInteger ans=a.multiply(b); System.out.println(ans); } }