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 listMay 23, 2024 07:14Maxim ElchuginMaxim ElchuginScore: 94,251Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1May 23, 2024 07:1491,89561,229,22932,001,0002,000,0002,506,752
2May 23, 2024 07:1493,61960,334,01434,639,00002,506,752
3May 23, 2024 07:1493,76561,139,37733,673,0001,020,0002,506,752
4May 23, 2024 07:1493,76564,560,90032,653,0002,040,0002,281,472
5May 23, 2024 07:1494,18161,179,10232,856,0001,991,0002,502,656
6May 23, 2024 07:1494,19764,653,63934,853,00002,506,752
7May 23, 2024 07:1494,25167,579,79132,881,0001,992,0002,281,472
8May 23, 2024 07:1494,26259,437,52833,881,000996,0002,281,472
9May 23, 2024 07:1494,32762,292,30131,910,0002,991,0002,281,472
10May 23, 2024 07:1496,066115,135,73935,544,48802,236,416
11May 23, 2024 07:1498,771106,925,50436,545,45002,215,936
12May 23, 2024 07:1499,06695,489,92036,654,32502,232,320