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 22, 2024 17:26Joad NacerJoad NacerScore: 67,335Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1May 22, 2024 17:2667,01454,448,02921,820,0002,975,0002,519,040
2May 22, 2024 17:2667,13555,061,93523,847,000993,0002,277,376
3May 22, 2024 17:2667,14950,597,26423,852,000993,0002,277,376
4May 22, 2024 17:2667,18151,681,30223,863,000994,0002,510,848
5May 22, 2024 17:2667,21651,524,51921,886,0002,984,0002,277,376
6May 22, 2024 17:2667,27656,101,72922,901,0001,991,0002,277,376
7May 22, 2024 17:2667,33549,380,48421,925,0002,989,0002,277,376
8May 22, 2024 17:2667,57656,155,52222,003,0003,000,0002,510,848
9May 22, 2024 17:2667,74352,704,62023,060,0002,005,0002,277,376
10May 22, 2024 17:2678,09899,192,76628,896,44302,273,280
11May 22, 2024 17:2678,11495,700,00528,902,35402,273,280
12May 22, 2024 17:2678,56890,240,54829,070,20502,260,992