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 listMay 5, 2026 07:56Victor MerckléVictor MerckléError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1May 5, 2026 07:57017,539,82002,313,0002,527,232expected "50928521902027 ", got "0 "stderr
2May 5, 2026 07:57018,145,73002,304,0002,527,232expected "51361190089520 ", got "0 "stderr
3May 5, 2026 07:57020,796,50302,353,0002,523,136expected "51594751219379 ", got "0 "stderr