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 listMay 27, 2024 18:40Matt StuchlikMatt StuchlikError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1May 27, 2024 18:4000000Error: Exit with code 1: Segmentation fault at address: 1082163328stderr
2May 27, 2024 18:4200000Error: expected "53689589536703073 ", got "53689609323082203 "
3May 27, 2024 18:4400000Error: expected "53689940661187574 ", got "53689946272308912 "
4May 27, 2024 18:4500000Error: expected "53691213214496607 ", got "53691261439237062 "
5May 27, 2024 18:4600000Error: Exit with code 1: Segmentation fault at address: 2416181376stderr
6May 27, 2024 18:4700000Error: Exit with code 1: Segmentation fault at address: 167804992stderr
7May 27, 2024 18:4800000Error: Exit with code 1: Segmentation fault at address: 302022672stderr
8May 27, 2024 18:506,185117,068,17551,337,92102,207,744
9May 27, 2024 18:506,191123,127,18851,387,65502,191,360
10May 27, 2024 18:496,258139,112,89851,938,80202,187,264
11May 27, 2024 18:436,273114,471,98952,063,68302,195,456
12May 27, 2024 18:506,302108,451,88652,309,50602,207,744
13May 27, 2024 18:496,309115,465,83452,361,25802,289,664
14May 27, 2024 18:436,326113,165,48152,507,80502,191,360
15May 27, 2024 18:496,340110,241,01052,622,81602,277,376
16May 27, 2024 18:436,420109,862,30453,285,29302,179,072