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 20, 2026 14:28olliecrowolliecrowError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Apr 20, 2026 14:300102,212,52689,559,0002,012,0002,273,280expected "51073251616318 ", got "51065775888051 "stderr
2Apr 20, 2026 14:300102,034,95489,662,0001,007,0002,260,992expected "51114537385950 ", got "51106660336761 "stderr
3Apr 20, 2026 14:300102,093,45489,264,0001,002,0002,457,600expected "50959251001276 ", got "50948023444924 "stderr