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 28, 2024 18:09Matthew SillsMatthew SillsScore: 95,211Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 28, 2024 18:0993,504109,826,27734,596,52502,256,896
2Jul 28, 2024 18:0994,68963,289,91934,034,0001,001,0002,273,280
3Jul 28, 2024 18:0994,97861,520,09833,134,0002,008,0002,289,664
4Jul 28, 2024 18:0995,03057,657,15733,152,0002,009,0002,519,040
5Jul 28, 2024 18:0995,06860,803,24533,165,0002,010,0002,531,328
6Jul 28, 2024 18:0995,19563,236,93233,210,0002,012,0002,523,136
7Jul 28, 2024 18:0995,21157,756,78933,215,0002,013,0002,277,376
8Jul 28, 2024 18:0995,24962,068,88634,236,0001,006,0002,289,664
9Jul 28, 2024 18:0995,28957,773,56434,250,0001,007,0002,355,200
10Jul 28, 2024 18:0995,38958,865,31033,278,0002,016,0002,289,664
11Jul 28, 2024 18:0997,586100,046,55736,106,87302,265,088
12Jul 28, 2024 18:0997,905106,001,69736,224,89502,269,184