Sum of prime numbers Andrey Tsvetkov

Compute the sum of all prime numbers in a stream of binary integers as fast as possible.

Input: 1 000 000 uint32 values in little-endian binary on STDIN (4 bytes each).

Output: The uint64 sum of all values that are prime, printed as a decimal string.

Back to listOct 3, 2023 21:47apuxbtapuxbtError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Oct 3, 2023 21:4600000Error: expected "51282644924141 ", got "51282644924112 "stderr
2Oct 3, 2023 21:4724,49749,509,83418,478,0003,079,0002,310,144
3Oct 3, 2023 21:4724,52242,555,15719,524,0002,055,0002,310,144
4Oct 3, 2023 21:4724,52650,327,44919,528,0002,055,0002,322,432
5Oct 3, 2023 21:4724,52646,087,59719,528,0002,055,0002,318,336
6Oct 3, 2023 21:4724,55642,425,33618,522,0003,087,0002,318,336
7Oct 3, 2023 21:4724,60147,386,63018,557,0003,092,0002,293,760
8Oct 3, 2023 21:4724,65557,912,49619,630,0002,066,0002,293,760
9Oct 3, 2023 21:4724,65852,414,73920,666,0001,033,0002,441,216
10Oct 3, 2023 21:4724,68851,550,24720,691,0001,034,0002,293,760
11Oct 3, 2023 21:4725,088100,003,82222,077,16702,289,664
12Oct 3, 2023 21:4725,10595,681,84922,092,74002,281,472
13Oct 3, 2023 21:4725,12984,127,55522,113,82002,285,568