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 listMay 22, 2024 19:50CemaCemaScore: 118,519Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1May 22, 2024 19:53116,74669,224,49141,187,0002,009,0002,498,560
2May 22, 2024 19:50116,94970,404,47541,259,0002,012,0002,281,472
3May 22, 2024 19:53117,05467,748,23640,289,0003,021,0002,281,472
4May 22, 2024 19:50117,16564,325,93440,327,0003,024,0002,281,472
5May 22, 2024 19:50117,20565,281,28041,349,0002,017,0002,281,472
6May 22, 2024 19:53117,22471,911,13541,356,0002,017,0002,502,656
7May 22, 2024 19:53117,26271,250,82742,378,0001,009,0002,281,472
8May 22, 2024 19:53117,51471,760,62242,469,0001,011,0002,351,104
9May 22, 2024 19:50117,71166,093,18242,541,0001,012,0002,281,472
10May 22, 2024 19:50117,76268,389,65742,559,0001,013,0002,363,392
11May 22, 2024 19:50117,93272,831,92943,635,00002,510,848
12May 22, 2024 19:53118,07667,975,46842,672,0001,016,0002,338,816
13May 22, 2024 19:50118,51969,804,75341,859,0001,993,0002,281,472
14May 22, 2024 19:50118,53070,677,02140,866,0002,990,0002,506,752
15May 22, 2024 19:53118,62465,092,28540,899,0002,992,0002,281,472
16May 22, 2024 19:53118,84965,367,71940,976,0002,998,0002,281,472
17May 22, 2024 19:53118,90368,085,99741,995,0001,999,0002,281,472
18May 22, 2024 19:50119,28670,369,04542,130,0002,006,0002,281,472
19May 22, 2024 19:53122,275116,621,41545,241,70202,232,320
20May 22, 2024 19:50122,377102,650,28945,279,50102,228,224
21May 22, 2024 19:50122,590109,024,35045,358,15002,228,224
22May 22, 2024 19:53123,182100,405,38545,577,35402,228,224
23May 22, 2024 19:50123,809103,161,87145,809,36702,224,128
24May 22, 2024 19:53161,483124,964,19059,748,82302,232,320