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 listApr 22, 2024 23:26Joad 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
1Apr 22, 2024 23:2600000Error: expected "51150850942734 ", got "51152995903987 "
2Apr 22, 2024 23:2600000Error: expected "50982336855027 ", got "50982384773608 "
3Apr 22, 2024 23:3100000Error: expected "50988322660802 ", got "50989709366235 "
4Apr 22, 2024 23:3100000Error: expected "51341775915356 ", got "51343105058314 "
5Apr 22, 2024 23:3200000Error: expected "51126125933523 ", got "51126622493872 "
6Apr 22, 2024 23:3256,486107,353,71349,707,83002,252,800
7Apr 22, 2024 23:2656,491115,289,38149,712,45802,256,896
8Apr 22, 2024 23:3256,528108,886,49649,745,03502,252,800
9Apr 22, 2024 23:2756,644117,825,58349,846,51302,252,800
10Apr 22, 2024 23:3256,676120,528,13249,874,92302,252,800
11Apr 22, 2024 23:2756,818105,332,00950,000,13802,256,896
12Apr 22, 2024 23:2656,868120,473,35050,044,00002,265,088
13Apr 22, 2024 23:2756,963115,917,37550,127,42502,256,896
14Apr 22, 2024 23:2656,966124,556,53850,130,15002,265,088