Arithmetic expressions Sergey Svistunov

Evaluate 100 arithmetic expressions as fast as possible.

Input

One expression per line on STDIN. Each expression contains 50,000 int16 numbers with operators +, -, *, / (integer division) and parentheses (, ).

-19550 - ((-14208 / (13583 + -19215)) + (-16832 / 797 + (9060 / -23627)) + ((-6060) + 24953))
30835 - 3703 - (-20089 * -6261 + ((-28985 - 29627) + (-17828 - (22773 / -4014) * 1630)))

Output

Print the int64 result of each expression, one per line, to STDOUT.

Back to listAug 17, 2026 02:46Victor MerckléVictor MerckléError
Source Code

Source code access is restricted. Log in to request access.

Challenge History
DateChallengerCostTypeStatus
Sep 4, 2026 12:48Tomislav Tunkovic10.00CustomSolution Broken
Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 4, 2026 12:51034,328,88422,567,0001,064,00053,248Exit with code 2: runtime: g 1: unexpected return pc for runtime.sigpanic called from 0x100009c8 stack: frame={sp:0x1224234e4d10, fp:0x1224234e4d70} stack=[0x1224234e4000,0x1224234e5000) 7 6 5 4 3 2 1 0 f e d c b a 9 8 012345678...stderr
2Aug 17, 2026 03:012,60283,788,32774,288,0001,187,0002,142,208stderr
3Aug 17, 2026 03:012,60383,981,99374,296,0001,212,0002,142,208stderr
4Aug 17, 2026 03:012,60483,925,57374,526,0001,010,0002,142,208stderr
5Aug 17, 2026 03:012,60683,919,37574,294,0001,280,0002,142,208stderr
6Aug 17, 2026 03:012,60784,096,59874,329,0001,275,0002,142,208stderr
7Aug 17, 2026 03:012,60784,024,39974,322,0001,288,0002,142,208stderr
8Aug 17, 2026 03:012,60783,916,73974,348,0001,278,0002,142,208stderr
9Aug 17, 2026 03:012,60883,972,41374,368,0001,281,0002,142,208stderr
10Aug 17, 2026 03:012,60984,072,69574,668,0001,013,0002,142,208stderr