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 9, 2025 12:36Alex KentAlex KentScore: 818,410Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jan 9, 2025 12:36816,693743,023,478716,691,0001,999,0002,277,376
2Jan 9, 2025 12:36817,291741,594,176719,216,00002,277,376
3Jan 9, 2025 12:36817,857746,386,657717,715,0001,999,0002,273,280
4Jan 9, 2025 12:36817,905742,767,590717,757,0001,999,0002,269,184
5Jan 9, 2025 12:36818,410746,305,170720,201,00002,281,472
6Jan 9, 2025 12:36818,436742,557,461719,224,0001,000,0002,367,488
7Jan 9, 2025 12:36818,642748,824,144718,407,0001,998,0002,289,664
8Jan 9, 2025 12:36819,441745,164,370720,108,0001,000,0002,265,088
9Jan 9, 2025 12:36820,358744,954,212720,916,000999,0002,281,472