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 11, 2021 06:57Sergey StreminSergey StreminScore: 132,873Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 11, 2021 06:57129,51176,862,66145,923,0001,996,0002,371,584
2Sep 11, 2021 06:57129,553113,504,81647,934,78502,260,992
3Sep 11, 2021 06:57130,28478,063,81847,201,0001,004,0002,363,392
4Sep 11, 2021 06:57130,28673,619,86746,198,0002,008,0002,367,488
5Sep 11, 2021 06:57130,59773,116,87547,315,0001,006,0002,289,664
6Sep 11, 2021 06:57132,508112,940,48049,027,97902,211,840
7Sep 11, 2021 06:57132,87375,100,89147,157,0002,006,0002,367,488
8Sep 11, 2021 06:57133,328121,788,08849,331,49702,211,840
9Sep 11, 2021 06:57133,60070,943,56149,432,00002,478,080
10Sep 11, 2021 06:57133,83274,706,51349,518,00002,371,584
11Sep 11, 2021 06:57134,98975,868,87847,949,0001,997,0002,469,888
12Sep 11, 2021 06:57136,76280,756,64049,590,0001,012,0002,289,664