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 listFeb 15, 2026 21:35zielajzielajScore: 3,341Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Feb 15, 2026 21:363,31121,163,9241,943,000971,0002,441,216
2Feb 15, 2026 21:363,31421,733,3381,944,000972,0002,514,944
3Feb 15, 2026 21:373,31516,797,8981,945,000972,0002,437,120
4Feb 15, 2026 21:333,31521,200,0861,945,000972,0002,437,120
5Feb 15, 2026 21:223,31724,430,3432,919,00002,437,120
6Feb 15, 2026 21:333,31920,621,2372,921,00002,441,216
7Feb 15, 2026 21:333,31920,143,8042,921,00002,437,120
8Feb 15, 2026 21:223,32215,659,6461,949,000974,0002,433,024
9Feb 15, 2026 21:383,32220,029,8921,949,000974,0002,510,848
10Feb 15, 2026 21:333,32221,143,3311,949,000974,0002,433,024
11Feb 15, 2026 21:383,32317,210,7342,924,00002,433,024
12Feb 15, 2026 21:373,32417,850,2901,950,000975,0002,510,848
13Feb 15, 2026 21:223,32516,667,8872,926,00002,437,120
14Feb 15, 2026 21:373,32721,086,2471,952,000976,0002,433,024
15Feb 15, 2026 21:333,32825,580,9251,953,000976,0002,441,216
16Feb 15, 2026 21:223,32820,992,0901,953,000976,0002,437,120
17Feb 15, 2026 21:383,32815,478,0501,953,000976,0002,433,024
18Feb 15, 2026 21:373,33017,210,1952,930,00002,428,928
19Feb 15, 2026 21:333,33321,262,5022,933,00002,428,928
20Feb 15, 2026 21:223,33420,305,8421,956,000978,0002,437,120
21Feb 15, 2026 21:223,33521,446,7412,935,00002,433,024
22Feb 15, 2026 21:223,34121,655,4321,960,000980,0002,437,120
23Feb 15, 2026 21:223,34316,724,3102,942,00002,437,120
24Feb 15, 2026 21:223,36819,269,5391,976,000988,0002,281,472
25Feb 15, 2026 21:233,38620,059,2921,987,000993,0002,437,120
26Feb 15, 2026 21:353,38918,317,2831,988,000994,0002,437,120
27Feb 15, 2026 21:233,38919,279,1011,988,000994,0002,433,024
28Feb 15, 2026 21:373,39324,039,9401,991,000995,0002,277,376
29Feb 15, 2026 21:223,39318,730,3681,991,000995,0002,437,120
30Feb 15, 2026 21:233,39719,607,2711,993,000996,0002,277,376
31Feb 15, 2026 21:383,40618,294,5031,998,000999,0002,437,120
32Feb 15, 2026 21:223,40721,996,9861,999,000999,0002,281,472
33Feb 15, 2026 21:333,43119,805,7362,013,0001,006,0002,437,120
34Feb 15, 2026 21:333,44321,703,2332,020,0001,010,0002,437,120
35Feb 15, 2026 21:383,44722,982,3072,022,0001,011,0002,281,472
36Feb 15, 2026 21:363,45318,493,3972,026,0001,013,0002,437,120
37Feb 15, 2026 21:383,46121,378,0482,031,0001,015,0002,428,928
38Feb 15, 2026 21:223,46725,302,1602,034,0001,017,0002,277,376
39Feb 15, 2026 21:373,76817,697,9753,316,00002,437,120
40Feb 15, 2026 21:353,80322,523,5113,347,00002,424,832
41Feb 15, 2026 21:333,84119,558,7543,380,00002,277,376
42Feb 15, 2026 21:353,90719,499,3492,292,0001,146,0002,433,024