TMUL - Not So Fast Multiplication
Multiply the given numbers.
Input
n [the number of multiplications ≤ 1000] l1 l2 [numbers to multiply (at most 10000 decimal digits each)]
Text grouped in [ ] does not appear in the input file.
Output
The results of multiplications.
Example
Input: 5 4 2 123 43 324 342 0 12 9999 12345 Output: 8 5289 110808 0 123437655
Warning: large Input/Output data, be careful with certain languages
hide comments
Vaporeon:
2015-06-01 21:41:41
I think the extreme cases aren't there in the judge.. :| |
|
drfgthyjuikjhgftrd:
2015-05-20 06:06:36
what to do getting wrong answer in c++ but correct in ideone |
|
/* Nitin Jaiman */:
2014-11-13 22:36:25
In java even karatsuba is not fast enough |
|
/* Nitin Jaiman */:
2014-11-13 22:36:25
why is it giving wrong answer with BigInteger in java |
|
/* Nitin Jaiman */:
2014-11-13 22:36:25
@ishita_2015 use try catch to get rid of NZEC put return in catch. |
|
Anubhav Balodhi :
2014-11-13 22:36:25
Karatsuba with BigInt, good learning ^_^ |
|
Steven Hans Limantoro:
2014-11-13 22:36:25
This is the same with MUL
|
|
ponnila:
2014-11-13 22:36:25
wat does compilation error mean
|
|
light_coder:
2014-11-13 22:36:25
I'm getting correct answer in my compiler for the above question. But on posting the same code it shows wrong answer..
|
|
arushi:
2014-11-13 22:36:25
dont know why it is showing runtime error and SIGSEGV???? in my pc my code is working! wat the hell! everything is correct then why???
|
Added by: | Darek Dereniowski |
Date: | 2004-10-19 |
Time limit: | 2.226s |
Source limit: | 50000B |
Memory limit: | 1536MB |
Cluster: | Cube (Intel G860) |
Languages: | All except: ASM32-GCC GAWK MAWK BC C-CLANG NCSHARP CPP14 CPP14-CLANG COBOL COFFEE D-CLANG D-DMD DART ELIXIR FANTOM FORTH GOSU GRV JS-MONKEY JULIA KTLN NIM NODEJS OBJC OBJC-CLANG OCT PICO PROLOG PYPY PYPY3 PY_NBC R RACKET RUST CHICKEN SED SQLITE SWIFT UNLAMBDA VB.NET |
Resource: | Copy of MUL problem with 12s time limit |