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 listAug 4, 2022 20:07Franek KortaFranek KortaScore: 101,051Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Aug 4, 2022 20:0797,53067,108,61533,079,0003,007,0002,527,232
2Aug 4, 2022 20:0798,05456,531,34133,257,0003,023,0002,281,472
3Aug 4, 2022 20:0798,73565,934,22935,518,0001,014,0002,281,472
4Aug 4, 2022 20:0799,91460,006,62435,969,000999,0002,281,472
5Aug 4, 2022 20:07100,00360,583,33034,001,0003,000,0002,277,376
6Aug 4, 2022 20:07100,64958,099,54036,234,0001,006,0002,281,472
7Aug 4, 2022 20:07101,05163,386,06736,379,0001,010,0002,527,232
8Aug 4, 2022 20:07102,257106,495,96737,834,99902,220,032
9Aug 4, 2022 20:07102,755109,294,20038,019,53102,224,128
10Aug 4, 2022 20:07103,234110,642,70238,196,50102,260,992
11Aug 4, 2022 20:07103,33862,116,74235,217,0003,018,0002,396,160
12Aug 4, 2022 20:07104,99769,360,29037,853,000996,0002,281,472