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 18:26Sergey StreminSergey StreminScore: 71,516Success
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 18:2670,84651,912,32124,197,0002,016,0002,490,368
2Sep 11, 2021 18:2770,98451,869,85225,254,0001,010,0002,486,272
3Sep 11, 2021 18:2771,04656,746,98425,276,0001,011,0002,506,752
4Sep 11, 2021 18:2771,09247,283,42925,293,0001,011,0002,371,584
5Sep 11, 2021 18:2771,13854,994,05126,321,00002,539,520
6Sep 11, 2021 18:2671,22749,964,23924,327,0002,027,0002,498,560
7Sep 11, 2021 18:2771,25953,720,22225,352,0001,014,0002,281,472
8Sep 11, 2021 18:2671,30048,930,57225,367,0001,014,0002,539,520
9Sep 11, 2021 18:2671,38449,669,31125,397,0001,015,0002,277,376
10Sep 11, 2021 18:2671,45147,558,21125,421,0001,016,0002,502,656
11Sep 11, 2021 18:2771,47652,993,45826,446,00002,281,472
12Sep 11, 2021 18:2671,47859,380,89025,430,0001,017,0002,494,464
13Sep 11, 2021 18:2771,51647,828,81425,444,0001,017,0002,490,368
14Sep 11, 2021 18:2671,56557,740,50026,479,00002,285,568
15Sep 11, 2021 18:2771,64348,800,23926,508,00002,498,560
16Sep 11, 2021 18:2771,64651,121,83425,490,0001,019,0002,494,464
17Sep 11, 2021 18:2671,66848,067,59125,498,0001,019,0002,498,560
18Sep 11, 2021 18:2671,80553,919,55426,568,00002,490,368
19Sep 11, 2021 18:2773,95891,096,18527,364,44602,195,456
20Sep 11, 2021 18:2674,04490,243,97927,396,40202,195,456
21Sep 11, 2021 18:2674,17898,442,44727,445,90502,256,896
22Sep 11, 2021 18:2674,22295,134,36827,461,96702,260,992
23Sep 11, 2021 18:2774,709106,911,23327,642,41302,203,648
24Sep 11, 2021 18:2775,15084,776,52127,805,53402,203,648