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 listAug 2, 2022 06:21Robert BurkeRobert BurkeScore: 75,616Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Aug 2, 2022 05:1073,44953,994,12526,170,0001,006,0002,428,928
2Aug 2, 2022 06:2173,98152,335,70027,373,00002,535,424
3Aug 2, 2022 06:2174,00350,685,95927,381,00002,437,120
4Aug 2, 2022 06:2174,17650,056,99727,445,00002,535,424
5Aug 2, 2022 06:2174,37650,806,72726,500,0001,019,0002,424,832
6Aug 2, 2022 05:1074,41147,345,33627,532,00002,535,424
7Aug 2, 2022 05:1074,71952,718,09126,623,0001,023,0002,273,280
8Aug 2, 2022 05:1074,81150,671,79627,680,00002,420,736
9Aug 2, 2022 05:1074,95456,540,08526,706,0001,027,0002,273,280
10Aug 2, 2022 05:1075,34654,496,67025,887,0001,991,0002,428,928
11Aug 2, 2022 06:2175,34951,972,58325,888,0001,991,0002,535,424
12Aug 2, 2022 06:2175,35751,250,54526,887,000995,0002,424,832
13Aug 2, 2022 06:2175,61651,502,68626,979,000999,0002,428,928
14Aug 2, 2022 05:1076,31946,126,73627,230,0001,008,0002,535,424
15Aug 2, 2022 06:2176,59746,129,39928,341,00002,428,928
16Aug 2, 2022 06:2176,61949,893,53427,337,0001,012,0002,416,640
17Aug 2, 2022 05:1077,24155,006,93627,559,0001,020,0002,535,424
18Aug 2, 2022 05:1078,06685,737,03728,884,26502,260,992
19Aug 2, 2022 05:1078,15149,473,20527,919,000997,0002,510,848
20Aug 2, 2022 05:1078,53363,824,41529,057,14802,265,088
21Aug 2, 2022 06:2178,99890,509,76729,229,34402,269,184
22Aug 2, 2022 06:2179,07983,892,35029,259,27902,260,992
23Aug 2, 2022 05:1079,16392,517,40929,290,45002,265,088
24Aug 2, 2022 06:2180,35284,275,75429,730,26002,269,184