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 20, 2025 12:26matsuoka-601matsuoka-601Error
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jan 20, 2025 12:2600000Error: expected "51557848243452 ", got "51557848243301 "stderr
2Jan 20, 2025 12:268,99124,948,9185,934,0001,978,0002,531,328
3Jan 20, 2025 12:268,99523,662,5975,937,0001,979,0002,301,952
4Jan 20, 2025 12:268,99830,385,4135,939,0001,979,0002,531,328