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 listOct 14, 2024 17:49Joad 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
1Oct 14, 2024 17:4700000Error: expected "429496465923 ", got "408021654847 "stderr
2Oct 14, 2024 17:4962,77345,418,89021,207,0002,019,0002,273,280
3Oct 14, 2024 17:4962,93250,691,65021,261,0002,024,0002,273,280
4Oct 14, 2024 17:4963,31442,806,97022,408,0001,018,0002,424,832