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 listDec 27, 2024 21:55Joad NacerJoad NacerError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Dec 27, 2024 21:5500000Error: expected "53691033552253478 ", got "53691033774997563 "stderr
2Dec 27, 2024 21:5500000Error: expected "53688321200299252 ", got "53688331351026527 "stderr
3Dec 27, 2024 21:5400000Error: expected "53689056799338771 ", got "53689074085147959 "stderr
4Dec 27, 2024 21:5400000Error: expected "53690195778220427 ", got "53690207814397071 "stderr
5Dec 27, 2024 21:554,23462,278,49034,142,0001,004,0002,306,048
6Dec 27, 2024 21:544,23961,692,03335,183,00002,535,424
7Dec 27, 2024 21:554,26761,316,61334,407,0001,011,0002,392,064
8Dec 27, 2024 21:544,27558,023,27533,453,0002,027,0002,531,328
9Dec 27, 2024 21:554,28361,454,92434,531,0001,015,0002,306,048
10Dec 27, 2024 21:554,28661,544,03434,561,0001,016,0002,301,952
11Dec 27, 2024 21:554,30165,022,57735,702,00002,306,048
12Dec 27, 2024 21:554,30761,622,37034,754,000992,0002,535,424
13Dec 27, 2024 21:544,31859,129,09435,838,00002,306,048
14Dec 27, 2024 21:554,33857,759,26335,002,0001,000,0002,531,328
15Dec 27, 2024 21:554,34459,291,91635,051,0001,001,0002,301,952
16Dec 27, 2024 21:554,35264,481,51134,112,0002,006,0002,297,856
17Dec 27, 2024 21:554,37659,195,85935,310,0001,008,0002,535,424
18Dec 27, 2024 21:544,37858,778,73035,331,0001,009,0002,297,856
19Dec 27, 2024 21:554,39459,085,59834,445,0002,026,0002,535,424
20Dec 27, 2024 21:554,43962,597,70136,844,00002,392,064
21Dec 27, 2024 21:554,44462,193,53536,882,00002,293,760
22Dec 27, 2024 21:544,44459,063,42835,889,000996,0002,301,952
23Dec 27, 2024 21:554,50856,829,80537,415,00002,535,424
24Dec 27, 2024 21:554,52860,230,13836,566,0001,015,0002,297,856
25Dec 27, 2024 21:544,55961,852,73136,841,000995,0002,531,328