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 13, 2021 19:06Andrey TsvetkovAndrey TsvetkovScore: 89,903Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 13, 2021 19:0688,90559,139,24029,905,0002,990,0002,519,040
2Jul 13, 2021 19:0689,40562,580,97130,073,0003,007,0002,334,720
3Jul 13, 2021 19:0689,63858,918,67531,156,0002,010,0002,531,328
4Jul 13, 2021 19:0689,70055,076,14430,172,0003,017,0002,527,232
5Jul 13, 2021 19:0689,88455,792,41230,234,0003,023,0002,334,720
6Jul 13, 2021 19:0689,90354,479,54031,248,0002,016,0002,387,968
7Jul 13, 2021 19:0689,90362,088,32930,240,0003,024,0002,342,912
8Jul 13, 2021 19:0689,98660,737,63230,269,0003,026,0002,514,944
9Jul 13, 2021 19:0691,01664,886,79432,656,0001,020,0002,527,232
10Jul 13, 2021 19:0691,477101,620,30033,846,57902,199,552
11Jul 13, 2021 19:0691,865124,204,61933,989,91602,199,552
12Jul 13, 2021 19:0692,467102,145,53734,212,81902,195,456