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 28, 2023 20:42Franek KortaFranek KortaScore: 92,427Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Aug 28, 2023 20:4290,43552,378,97133,461,00002,437,120
2Aug 28, 2023 20:4290,61654,459,87433,528,00002,265,088
3Aug 28, 2023 20:4290,98959,323,18533,666,00002,531,328
4Aug 28, 2023 20:4291,49759,417,64632,859,000995,0002,269,184
5Aug 28, 2023 20:4291,70856,977,09730,938,0002,994,0002,269,184
6Aug 28, 2023 20:4291,73255,795,93031,945,0001,996,0002,527,232
7Aug 28, 2023 20:4292,42759,158,18932,187,0002,011,0002,437,120
8Aug 28, 2023 20:4292,96562,566,47334,397,00002,527,232
9Aug 28, 2023 20:4293,46563,657,87334,582,00002,449,408
10Aug 28, 2023 20:4296,703104,596,79235,780,08202,285,568
11Aug 28, 2023 20:4296,72691,099,73835,788,80102,289,664
12Aug 28, 2023 20:4297,21894,832,60335,970,59802,224,128