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 17:24Matthew SillsMatthew SillsScore: 109,846Success
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 17:24108,74666,506,58938,225,0002,011,0002,269,184
2Jul 28, 2024 17:24108,92263,352,43238,286,0002,015,0002,289,664
3Jul 28, 2024 17:24109,01462,915,02038,319,0002,016,0002,289,664
4Jul 28, 2024 17:24109,15166,271,54639,377,0001,009,0002,523,136
5Jul 28, 2024 17:24109,18462,388,94539,389,0001,009,0002,289,664
6Jul 28, 2024 17:24109,19261,892,96739,391,0001,010,0002,519,040
7Jul 28, 2024 17:24109,84669,909,96339,627,0001,016,0002,289,664
8Jul 28, 2024 17:24109,91168,402,42839,651,0001,016,0002,277,376
9Jul 28, 2024 17:24110,04366,941,85540,716,00002,363,392
10Jul 28, 2024 17:24111,39397,530,13741,215,23202,269,184
11Jul 28, 2024 17:24112,345111,627,78541,567,74902,265,088
12Jul 28, 2024 17:24113,557108,585,37842,015,93002,260,992