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 listJul 27, 2024 17:22Matthew SillsMatthew SillsScore: 109,859Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 27, 2024 17:22108,81165,578,17939,254,0001,006,0002,269,184
2Jul 27, 2024 17:22108,86564,121,16438,266,0002,014,0002,523,136
3Jul 27, 2024 17:22108,95165,065,34538,297,0002,015,0002,289,664
4Jul 27, 2024 17:22109,11962,668,44540,374,00002,269,184
5Jul 27, 2024 17:22109,35170,812,93639,449,0001,011,0002,289,664
6Jul 27, 2024 17:22109,40563,865,65039,468,0001,012,0002,269,184
7Jul 27, 2024 17:22109,85974,563,87039,632,0001,016,0002,289,664
8Jul 27, 2024 17:22109,89268,318,19539,644,0001,016,0002,523,136
9Jul 27, 2024 17:22112,067113,360,82841,464,94102,273,280
10Jul 27, 2024 17:22112,32199,362,80841,558,86402,277,376
11Jul 27, 2024 17:22112,559102,068,07341,646,88102,273,280
12Jul 27, 2024 17:22125,93074,384,76945,582,0001,012,0002,531,328