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 7, 2024 11:47GraceGraceError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jun 7, 2024 11:4700000Error: expected "53687543193050107 ", got "53687676735423595 "stderr
2Jun 7, 2024 11:4741,927408,596,824347,989,96902,236,416
3Jun 7, 2024 11:4741,959409,663,759348,255,68202,240,512
4Jun 7, 2024 11:4741,989413,928,549348,510,33902,248,704
5Jun 7, 2024 11:4742,008418,546,754348,666,57002,228,224
6Jun 7, 2024 11:4742,081412,677,888349,274,57602,240,512
7Jun 7, 2024 11:4742,208400,154,337350,330,43102,244,608
8Jun 7, 2024 11:4742,244419,176,374350,621,82302,240,512
9Jun 7, 2024 11:4743,026449,885,003357,113,94602,248,704
10Jun 7, 2024 11:4743,124419,218,861357,931,86802,240,512