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 13:55Andrey TsvetkovAndrey TsvetkovScore: 89,511Success
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 13:5588,18461,104,92531,609,0001,019,0002,506,752
2Jul 15, 2021 13:5588,23566,005,97731,627,0001,020,0002,334,720
3Jul 15, 2021 13:5588,26261,480,43631,637,0001,020,0002,514,944
4Jul 15, 2021 13:5588,80058,828,79130,865,0001,991,0002,510,848
5Jul 15, 2021 13:5588,80561,998,72729,871,0002,987,0002,334,720
6Jul 15, 2021 13:5588,84163,612,46529,883,0002,988,0002,334,720
7Jul 15, 2021 13:5588,84359,170,03330,880,0001,992,0002,514,944
8Jul 15, 2021 13:5589,51163,810,67931,112,0002,007,0002,519,040
9Jul 15, 2021 13:5589,60562,083,52530,140,0003,014,0002,334,720
10Jul 15, 2021 13:5589,953110,283,27933,282,51402,191,360
11Jul 15, 2021 13:5590,016101,585,63233,305,80302,187,264
12Jul 15, 2021 13:5490,22390,114,98533,382,60202,191,360
13Jul 15, 2021 13:5490,30493,254,34433,412,47402,195,456
14Jul 15, 2021 13:5590,78395,543,24733,589,84102,195,456
15Jul 15, 2021 13:5490,904102,942,71933,634,65802,183,168