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 22, 2023 18:31mmalczakmmalczakScore: 84,205Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 22, 2023 17:4083,36557,702,44428,855,0001,990,0002,289,664
2Sep 22, 2023 17:4083,44155,201,25930,873,00002,289,664
3Sep 22, 2023 17:4083,63554,114,22528,949,0001,996,0002,269,184
4Sep 22, 2023 17:4083,67657,182,81928,963,0001,997,0002,269,184
5Sep 22, 2023 17:4083,68654,982,73529,966,000998,0002,289,664
6Sep 22, 2023 18:3183,72757,654,29528,981,0001,998,0002,277,376
7Sep 22, 2023 18:3183,84952,960,63929,023,0002,001,0002,289,664
8Sep 22, 2023 18:3183,92252,456,61429,048,0002,003,0002,289,664
9Sep 22, 2023 18:3184,01654,818,94429,081,0002,005,0002,289,664
10Sep 22, 2023 17:4084,04160,175,82829,089,0002,006,0002,519,040
11Sep 22, 2023 18:3184,04656,597,99030,094,0001,003,0002,289,664
12Sep 22, 2023 18:3184,15156,358,17629,128,0002,008,0002,289,664
13Sep 22, 2023 18:3184,20554,103,20330,151,0001,005,0002,277,376
14Sep 22, 2023 17:4084,28151,745,38029,173,0002,011,0002,285,568
15Sep 22, 2023 17:4084,34354,274,66029,194,0002,013,0002,273,280
16Sep 22, 2023 18:3184,49253,633,81330,254,0001,008,0002,289,664
17Sep 22, 2023 17:4084,52756,688,73430,267,0001,008,0002,277,376
18Sep 22, 2023 18:3184,59557,073,52029,281,0002,019,0002,273,280
19Sep 22, 2023 18:3185,356102,115,28431,581,55802,265,088
20Sep 22, 2023 18:3185,56195,037,96431,657,62202,277,376
21Sep 22, 2023 17:4085,69987,593,60831,708,66102,265,088
22Sep 22, 2023 17:4085,857100,154,18431,766,90802,277,376
23Sep 22, 2023 17:4086,35491,975,44431,950,85502,269,184
24Sep 22, 2023 18:3186,634104,031,24332,054,54702,269,184