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 listJun 29, 2026 15:25Victor 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
1Jun 29, 2026 15:27011,831,7014,071,00002,113,536expected "51162891211078 ", got "51162896046287 "
2Jun 29, 2026 15:274,61811,807,4454,064,00002,113,536
3Jun 29, 2026 15:274,61911,749,7144,065,00002,113,536
4Jun 29, 2026 15:274,74311,831,9554,174,00002,113,536
5Jun 29, 2026 15:274,75111,843,4714,181,00002,113,536
6Jun 29, 2026 15:274,75111,851,6704,181,00002,113,536
7Jun 29, 2026 15:274,76012,359,1064,189,00002,113,536
8Jun 29, 2026 15:274,77611,909,0304,203,00002,113,536
9Jun 29, 2026 15:274,83711,923,2734,257,00002,113,536