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 listJul 15, 2021 11:04Andrey TsvetkovAndrey TsvetkovScore: 85,727Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 15, 2021 11:0484,90555,963,48230,402,0001,013,0002,506,752
2Jul 15, 2021 11:0484,99257,315,37830,433,0001,014,0002,334,720
3Jul 15, 2021 11:0485,07354,831,45230,462,0001,015,0002,334,720
4Jul 15, 2021 11:0485,09253,177,54730,469,0001,015,0002,334,720
5Jul 15, 2021 11:0485,14357,763,10530,487,0001,016,0002,506,752
6Jul 15, 2021 11:0485,23255,096,95530,519,0001,017,0002,334,720
7Jul 15, 2021 11:0485,72756,099,86729,673,0002,046,0002,334,720
8Jul 15, 2021 11:0486,11663,856,67928,876,0002,987,0002,498,560
9Jul 15, 2021 11:0486,14655,970,18429,882,0001,992,0002,498,560
10Jul 15, 2021 11:0488,63795,791,57232,795,79102,179,072
11Jul 15, 2021 11:0488,83195,606,42832,867,62702,174,976
12Jul 15, 2021 11:0489,45096,924,72433,096,65902,183,168