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 5, 2024 12:34Matt 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
1Jun 5, 2024 12:4700000Error: expected "53690324504826411 ", got "53690390980611261 "
2Jun 5, 2024 12:3900000Error: expected "53681876422157631 ", got "53681959829111891 "
3Jun 5, 2024 12:4000000Error: expected "53689479743225495 ", got "53689490873606178 "
4Jun 5, 2024 12:4000000Error: Exit with code 1: Segmentation fault at address: 378164751872stderr
5Jun 5, 2024 12:4100000Error: Exit with code 1: Segmentation fault at address: 378164751872stderr
6Jun 5, 2024 12:4200000Error: expected "53683528867502414 ", got "53683529775280216 "
7Jun 5, 2024 12:4300000Error: expected "53686737534297141 ", got "53686753649100383 "
8Jun 5, 2024 12:4300000Error: Exit with code 1: Segmentation fault at address: 380921491968stderr
9Jun 5, 2024 12:4400000Error: expected "53691538305111121 ", got "53691558091490251 "
10Jun 5, 2024 12:4400000Error: expected "53689470066102105 ", got "53689444466102105 "
11Jun 5, 2024 12:4600000Error: expected "53689162416629347 ", got "53689168027750685 "
12Jun 5, 2024 12:4600000Error: Exit with code 1: Segmentation fault at address: 378349335040stderr
13Jun 5, 2024 12:3900000Error: expected "53687679810381464 ", got "53687691700676210 "
14Jun 5, 2024 12:4800000Error: expected "53690007041257615 ", got "53690020559688702 "
15Jun 5, 2024 12:4800000Error: expected "53689298789317321 ", got "53689490155417492 "
16Jun 5, 2024 12:4900000Error: expected "53681546028145637 ", got "53681934566550961 "
17Jun 5, 2024 12:4900000Error: expected "53683598056424547 ", got "53683595496424547 "
18Jun 5, 2024 13:0500000Error: expected "53690136780753924 ", got "53690316239055868 "
19Jun 5, 2024 13:0500000Error: Exit with code 1: Segmentation fault at address: 401602601472stderr
20Jun 5, 2024 13:0600000Error: expected "53690225553213818 ", got "53690321995452320 "
21Jun 5, 2024 13:0600000Error: expected "53686117814268983 ", got "53686165111828098 "
22Jun 5, 2024 13:0700000Error: expected "53680962815453000 ", got "53681003885812883 "
23Jun 5, 2024 13:0800000Error: expected "53681627567678320 ", got "53681682006863485 "
24Jun 5, 2024 13:0800000Error: Exit with code 1: Segmentation fault at address: 378349334976stderr
25Jun 5, 2024 12:3800000Error: expected "53686086237583048 ", got "53686108095435477 "
26Jun 5, 2024 12:3700000Error: expected "53689426971619248 ", got "53689448568462189 "
27Jun 5, 2024 12:3700000Error: expected "53682312772854858 ", got "53682328699978922 "
28Jun 5, 2024 12:3600000Error: expected "53683624079446101 ", got "53683678518631266 "
29Jun 5, 2024 12:3600000Error: expected "53688083636335327 ", got "53688308684620520 "
30Jun 5, 2024 12:3500000Error: expected "53689275267484595 ", got "53689536936187940 "
31Jun 5, 2024 12:3500000Error: expected "53691634053558563 ", got "53691700529343413 "
32Jun 5, 2024 12:3400000Error: expected "53692007274770712 ", got "53692079470531444 "
33Jun 5, 2024 12:505,45098,608,58545,237,97102,297,856
34Jun 5, 2024 12:505,454100,425,68045,267,40502,301,952
35Jun 5, 2024 12:415,46999,558,56845,394,36502,289,664
36Jun 5, 2024 12:505,495110,719,56445,606,28102,269,184
37Jun 5, 2024 12:455,510110,867,93345,728,86002,281,472
38Jun 5, 2024 13:035,512112,792,66345,751,92902,306,048
39Jun 5, 2024 13:095,517110,169,35145,788,02302,285,568
40Jun 5, 2024 13:035,540112,110,99645,983,14902,289,664
41Jun 5, 2024 12:455,543118,862,38246,005,01102,289,664
42Jun 5, 2024 12:415,544123,900,53846,012,02902,285,568
43Jun 5, 2024 12:455,54997,309,48846,055,78702,281,472
44Jun 5, 2024 12:415,560122,256,00546,151,46302,297,856
45Jun 5, 2024 13:095,568115,856,72146,217,50102,273,280
46Jun 5, 2024 13:095,596105,346,08246,447,29902,183,168
47Jun 5, 2024 13:035,59796,665,55446,455,49402,301,952