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 15, 2021 16:02piculpiculScore: 108,224Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 15, 2021 16:02106,39768,468,63137,349,0002,018,0002,289,664
2Sep 15, 2021 16:02107,64167,290,68937,836,0001,991,0002,289,664
3Sep 15, 2021 16:02107,66869,036,13138,842,000995,0002,289,664
4Sep 15, 2021 16:02107,68471,567,30438,847,000996,0002,519,040
5Sep 15, 2021 16:02107,86564,052,14738,913,000997,0002,523,136
6Sep 15, 2021 16:02108,05463,070,08437,981,0001,999,0002,519,040
7Sep 15, 2021 16:02108,22463,218,66738,041,0002,002,0002,289,664
8Sep 15, 2021 16:02109,88167,017,39040,656,00002,269,184
9Sep 15, 2021 16:02110,37664,673,41638,847,0001,992,0002,523,136
10Sep 15, 2021 16:02117,637105,279,49743,525,85602,252,800
11Sep 15, 2021 16:02117,673125,028,37043,539,06502,256,896
12Sep 15, 2021 16:02118,192123,314,65243,730,89002,256,896