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 19, 2023 08:11mmalczakmmalczakScore: 84,324Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 19, 2023 08:1182,93860,821,93329,665,0001,022,0002,269,184
2Sep 19, 2023 08:1182,96563,005,11329,674,0001,023,0002,289,664
3Sep 19, 2023 08:1183,31156,041,55828,837,0001,988,0002,269,184
4Sep 19, 2023 08:1183,34662,632,00828,849,0001,989,0002,265,088
5Sep 19, 2023 08:1183,37052,737,92429,852,000995,0002,273,280
6Sep 19, 2023 08:1183,43557,117,87428,880,0001,991,0002,289,664
7Sep 19, 2023 08:1183,45957,317,50128,888,0001,992,0002,281,472
8Sep 19, 2023 08:1183,46558,241,95729,853,0001,029,0002,269,184
9Sep 19, 2023 08:1183,58659,596,61328,932,0001,995,0002,289,664
10Sep 19, 2023 08:1183,60556,061,03728,939,0001,995,0002,523,136
11Sep 19, 2023 08:1184,17853,712,64330,142,0001,004,0002,281,472
12Sep 19, 2023 08:1184,23253,760,15129,156,0002,010,0002,269,184
13Sep 19, 2023 08:1184,32453,288,58629,188,0002,012,0002,289,664
14Sep 19, 2023 08:1184,42753,880,11629,223,0002,015,0002,289,664
15Sep 19, 2023 08:1184,51952,870,49829,255,0002,017,0002,289,664
16Sep 19, 2023 08:1184,75753,992,33130,349,0001,011,0002,265,088
17Sep 19, 2023 08:1184,77355,240,30630,355,0001,011,0002,273,280
18Sep 19, 2023 08:1185,54662,483,30330,631,0001,021,0002,289,664
19Sep 19, 2023 08:1185,75397,380,23331,728,46702,269,184
20Sep 19, 2023 08:1185,90394,216,17731,784,23702,260,992
21Sep 19, 2023 08:1185,976111,462,93431,810,96202,256,896
22Sep 19, 2023 08:1186,23792,127,30731,907,86502,265,088
23Sep 19, 2023 08:1186,39195,566,77131,964,57602,269,184
24Sep 19, 2023 08:1186,815100,904,64032,121,38902,256,896