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 listJul 13, 2021 10:58Andrey TsvetkovAndrey TsvetkovScore: 105,616Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 13, 2021 10:58105,01462,406,11436,863,0001,992,0002,523,136
2Jul 13, 2021 10:58105,10868,203,00935,899,0002,991,0002,334,720
3Jul 13, 2021 10:58105,25465,254,06136,947,0001,997,0002,527,232
4Jul 13, 2021 10:58105,31465,591,23235,969,0002,997,0002,326,528
5Jul 13, 2021 10:58105,39765,187,06836,998,0001,999,0002,519,040
6Jul 13, 2021 10:58105,48664,061,97037,029,0002,001,0002,334,720
7Jul 13, 2021 10:58105,61664,904,08436,072,0003,006,0002,527,232
8Jul 13, 2021 10:58105,65458,188,12437,088,0002,004,0002,387,968
9Jul 13, 2021 10:58105,67868,203,35437,096,0002,005,0002,322,432
10Jul 13, 2021 10:58108,513103,935,41340,149,68102,203,648
11Jul 13, 2021 10:58108,81297,326,35740,260,32902,207,744
12Jul 13, 2021 10:58109,015112,071,34040,335,57702,207,744