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:39Matthew SillsMatthew SillsScore: 109,865Success
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:39108,95163,598,19338,297,0002,015,0002,289,664
2Jul 27, 2024 17:39109,07059,706,73938,339,0002,017,0002,527,232
3Jul 27, 2024 17:39109,08465,151,34238,343,0002,018,0002,273,280
4Jul 27, 2024 17:39109,21666,746,28239,400,0001,010,0002,277,376
5Jul 27, 2024 17:39109,37662,843,29238,446,0002,023,0002,269,184
6Jul 27, 2024 17:39109,45162,949,55839,485,0001,012,0002,527,232
7Jul 27, 2024 17:39109,86570,058,04939,634,0001,016,0002,269,184
8Jul 27, 2024 17:39109,98467,533,38939,677,0001,017,0002,289,664
9Jul 27, 2024 17:39111,30699,579,07041,183,28702,273,280
10Jul 27, 2024 17:39112,612110,539,83441,666,45002,260,992
11Jul 27, 2024 17:39113,424107,137,86541,966,79602,260,992
12Jul 27, 2024 17:39117,19571,608,94041,346,0002,016,0002,289,664