Parse integers Sergey Svistunov

Compute the sum of integers read from STDIN as fast as possible.

Input: 50 000 000 lines, each containing one integer in the range [0; 2147483647].

629871117
2024562523
1372689083
1021777120
2111176472

Output: The uint64 sum of all numbers, printed as a decimal string.

Note: Integer overflow is expected – use a 64-bit accumulator.

Back to listJun 4, 2024 04:47matsuoka-601matsuoka-601Error
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jun 4, 2024 04:4700000Error: expected "53684567887026105 ", got "ok: 7861667456234986594 1000 0000 1000 0000 1000 0000 0010 0000 5 9 7 1597635 1001 0000 0000 0100 0000 0001 0000 0000 8 9 9 25736335 1000 0010 0000 0010 0000 0001 0000 0000 8 8 7 27419149 "
2Jun 4, 2024 04:5000000Error: expected "53690727357003632 ", got "ok: 7861667456234986594 1000 0000 1000 0000 0100 0001 0000 0000 8 5 8 15232375 "
3Jun 4, 2024 04:5100000Error: expected "53682673709392907 ", got "ok: 7861667456234986594 1000 0000 0100 0000 0001 0000 0000 0100 2 9 9 16795040 1000 0000 1000 0000 1000 0000 0010 0000 5 9 7 20828250 1001 0000 0000 0100 0000 0001 0000 0000 8 9 9 44966950 1000 0010 0000 0010 ...
4Jun 4, 2024 04:5200000Error: expected "53689219337893251 ", got "ok: 7861667456234986594 1000 0000 1000 0000 0100 0001 0000 0000 8 5 8 21477463 "
5Jun 4, 2024 04:5300000Error: expected "53689770883289839 ", got "ok: 7861667456234986594 1000 0000 1000 0000 0100 0001 0000 0000 8 5 8 11938581 "
6Jun 4, 2024 04:5400000Error: expected "53689899707344629 ", got "ok: 7861667456234986594 1000 0000 1000 0000 0100 0001 0000 0000 8 5 8 20984344 "
7Jun 4, 2024 04:5500000Error: expected "53690670967235597 ", got "ok: 7861667456234986594 1000 0000 1000 0000 0100 0001 0000 0000 8 5 8 14079540 "
8Jun 4, 2024 04:5700000Error: expected "53689955206053216 ", got "ok: 7861667456234986594 1000 0000 1000 0000 0100 0001 0000 0000 8 5 8 11603891 "