fork download
  1. import java.io.*;
  2. import java.util.*;
  3. import java.text.*;
  4. import java.math.*;
  5. import java.util.regex.*;
  6.  
  7. /* Name of the class has to be "Main" only if the class is public. */
  8. class Ideone
  9. {
  10. public static void main (String[] args) throws java.lang.Exception
  11. {
  12. Scanner l=new Scanner(System.in);
  13. BigInteger a=l.nextBigInteger();
  14. BigInteger b=l.nextBigInteger();
  15. System.out.println(a.multiply(b));
  16.  
  17. }
  18. }
Success #stdin #stdout 0.06s 4386816KB
stdin
123456789123456789123456789123456789
789456123789456123789456123789456123789
stdout
97463718196896483296329248395762013397674748819241983719809218620376453521