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 listJan 15, 2025 07:52Ian MckibbenIan MckibbenScore: 7,357,430Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jan 15, 2025 07:527,281,2646,436,133,9146,406,513,000999,0002,265,088
2Jan 15, 2025 07:527,315,0856,463,995,6396,435,276,0001,999,0002,281,472
3Jan 15, 2025 07:527,323,5536,472,348,5886,442,728,0001,999,0002,281,472
4Jan 15, 2025 07:527,342,2356,485,606,5536,457,169,0003,998,0002,265,088
5Jan 15, 2025 07:527,357,4306,505,119,4976,473,539,000999,0002,281,472
6Jan 15, 2025 07:527,364,7206,507,615,5786,478,955,0001,999,0002,289,664
7Jan 15, 2025 07:527,372,4016,515,194,8866,486,714,000999,0002,281,472
8Jan 15, 2025 07:527,378,5116,522,647,0596,493,090,00002,293,760
9Jan 15, 2025 07:527,398,8416,535,810,3356,509,981,000999,0002,289,664