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 listJul 3, 2026 03:37Victor 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
1Jul 3, 2026 03:39011,729,9084,000,00002,117,632expected "51101538873683 ", got "51102086954196 "stderr
2Jul 3, 2026 03:394,38911,648,7813,863,00002,117,632stderr
3Jul 3, 2026 03:394,48611,676,3893,948,00002,117,632stderr
4Jul 3, 2026 03:394,52111,680,8213,979,00002,117,632stderr
5Jul 3, 2026 03:394,52511,678,2463,982,00002,117,632stderr
6Jul 3, 2026 03:394,52611,656,6453,983,00002,117,632stderr
7Jul 3, 2026 03:394,54012,007,6363,996,00002,117,632stderr
8Jul 3, 2026 03:394,54711,706,3384,002,00002,117,632stderr
9Jul 3, 2026 03:394,56011,844,5714,013,00002,117,632stderr