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 23, 2026 21:44Pavel SkripkinPavel SkripkinError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Apr 23, 2026 21:470141,537,131122,546,0001,004,0002,433,024expected "51321179598055 ", got "51321179518477 "
2Apr 23, 2026 21:470142,026,104121,832,0001,997,0002,437,120expected "51291915513270 ", got "51291915427039 "
3Apr 23, 2026 21:470140,508,081123,100,0002,001,0002,433,024expected "51112939234364 ", got "51112939124284 "