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 listOct 3, 2023 11:24apuxbtapuxbtError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Oct 3, 2023 11:2400000Error: expected "429496419036 ", got "335007259698 "stderr
2Oct 3, 2023 11:2480,18492,561,67529,668,17102,273,280
3Oct 3, 2023 11:2480,76291,843,30029,882,01602,256,896
4Oct 3, 2023 11:2480,91193,962,47429,937,10802,256,896
5Oct 3, 2023 11:2481,153101,097,59530,026,45602,260,992
6Oct 3, 2023 11:2481,54989,126,07230,173,11002,265,088
7Oct 3, 2023 11:2482,164104,222,79330,400,60502,256,896