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 listSep 16, 2023 11:40mmalczakmmalczakScore: 99,454Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 16, 2023 11:4096,92466,059,51333,870,0001,992,0002,289,664
2Sep 16, 2023 11:4097,71161,710,63634,145,0002,008,0002,289,664
3Sep 16, 2023 11:4097,84661,557,86234,192,0002,011,0002,289,664
4Sep 16, 2023 11:4098,21663,822,21534,322,0002,018,0002,289,664
5Sep 16, 2023 11:4098,54161,546,89436,460,00002,289,664
6Sep 16, 2023 11:4098,74362,632,23536,535,00002,289,664
7Sep 16, 2023 11:4099,45462,826,06835,804,000994,0002,289,664
8Sep 16, 2023 11:4099,580104,194,25836,844,73502,273,280
9Sep 16, 2023 11:4099,61466,248,25035,861,000996,0002,289,664
10Sep 16, 2023 11:4099,783114,623,99436,919,55002,277,376
11Sep 16, 2023 11:40100,103114,917,94137,038,02202,265,088
12Sep 16, 2023 11:40102,41458,784,38535,899,0001,994,0002,277,376