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 21, 2025 05:00Steve 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 21, 2025 05:0000000Error: expected "429496530495 ", got "429496530495c: 429496486582 m: d: -43913 "stderr
2Apr 21, 2025 05:0073,18450,377,72125,073,0002,005,0002,437,120
3Apr 21, 2025 05:0073,24150,101,38323,085,0004,014,0002,527,232
4Apr 21, 2025 05:0073,66556,133,65225,237,0002,019,0002,424,832