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 19, 2024 14:37Huy Duc LeHuy Duc LeScore: 35,152Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Feb 19, 2024 14:3734,91995,425,28730,728,35402,220,032
2Feb 19, 2024 14:3734,979104,936,57730,781,78202,228,224
3Feb 19, 2024 14:3735,087113,389,41830,876,34902,215,936
4Feb 19, 2024 14:3735,09958,555,52029,891,000996,0002,289,664
5Feb 19, 2024 14:3735,10060,894,72329,892,000996,0002,289,664
6Feb 19, 2024 14:3735,14159,221,30029,894,0001,030,0002,494,464
7Feb 19, 2024 14:3735,15253,311,97528,939,0001,995,0002,490,368
8Feb 19, 2024 14:3735,15554,320,54628,941,0001,995,0002,486,272
9Feb 19, 2024 14:3735,20959,479,11428,985,0001,999,0002,289,664
10Feb 19, 2024 14:3735,24253,796,84929,013,0002,000,0002,486,272
11Feb 19, 2024 14:3735,32260,901,98030,081,0001,002,0002,289,664
12Feb 19, 2024 14:3735,35851,794,25929,108,0002,007,0002,330,624