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 listNov 27, 2024 21:46Joad NacerJoad NacerError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Nov 27, 2024 21:4600000Error: expected "51208705337175 ", got "51209024777944 "stderr
2Nov 27, 2024 21:4600000Error: expected "51081579047555 ", got "51081771029164 "stderr
3Nov 27, 2024 21:4600000Error: expected "51255014355278 ", got "51256644417531 "stderr
4Nov 27, 2024 21:46197,165193,222,679173,505,00002,437,120
5Nov 27, 2024 21:46197,302199,404,555173,626,00002,535,424
6Nov 27, 2024 21:46198,278196,090,682173,483,0001,002,0002,273,280