TopK Sergey Svistunov

Find the sum of the 100 largest values in a stream of binary integers as fast as possible.

Input: 100 000 000 uint32 values in little-endian binary on STDIN (4 bytes each).

Output: The uint64 sum of the top 100 greatest values, printed as a decimal string.

Back to listApr 22, 2025 20:40Steve BronderSteve BronderError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Apr 22, 2025 20:3900000Error: expected "429496500808 ", got "429496500808c: 429496486582 m: d: -14226 "stderr
2Apr 22, 2025 20:4070,08148,503,85723,936,0001,994,0002,273,280
3Apr 22, 2025 20:4070,35749,194,60625,031,0001,001,0002,519,040
4Apr 22, 2025 20:4070,49549,228,01725,080,0001,003,0002,539,520