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 16, 2023 11:59mmalczakmmalczakScore: 108,751Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 16, 2023 11:5999,459106,889,08836,799,99702,273,280
2Sep 16, 2023 11:5999,475106,839,77036,805,81902,269,184
3Sep 16, 2023 12:0099,528101,341,90436,825,31002,260,992
4Sep 16, 2023 12:00100,061103,677,96037,022,48802,252,800
5Sep 16, 2023 12:00100,215109,946,62837,079,40702,265,088
6Sep 16, 2023 11:59100,508102,160,55037,187,83002,260,992
7Sep 16, 2023 11:59108,57362,579,65438,164,0002,008,0002,273,280
8Sep 16, 2023 12:00108,60368,200,16638,174,0002,009,0002,527,232
9Sep 16, 2023 12:00108,63067,611,17938,184,0002,009,0002,289,664
10Sep 16, 2023 11:59108,68168,338,33438,202,0002,010,0002,289,664
11Sep 16, 2023 12:00108,69768,196,62339,213,0001,005,0002,289,664
12Sep 16, 2023 12:00108,70561,686,39438,210,0002,011,0002,273,280
13Sep 16, 2023 11:59108,75163,063,20938,227,0002,011,0002,531,328
14Sep 16, 2023 12:00108,75963,988,28738,229,0002,012,0002,289,664
15Sep 16, 2023 11:59108,93068,453,02639,297,0001,007,0002,289,664
16Sep 16, 2023 11:59108,93870,993,57238,292,0002,015,0002,289,664
17Sep 16, 2023 11:59108,97869,298,63638,306,0002,016,0002,289,664
18Sep 16, 2023 12:00109,05462,852,42638,333,0002,017,0002,285,568
19Sep 16, 2023 12:00109,52761,212,82839,512,0001,013,0002,289,664
20Sep 16, 2023 11:59109,56567,517,68339,526,0001,013,0002,289,664
21Sep 16, 2023 12:00109,78171,260,92739,604,0001,015,0002,289,664
22Sep 16, 2023 11:59109,83570,802,28240,639,00002,527,232
23Sep 16, 2023 12:00109,89270,680,66639,644,0001,016,0002,289,664
24Sep 16, 2023 11:59109,93272,967,37639,659,0001,016,0002,289,664