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 6, 2022 19:15Franek KortaFranek KortaScore: 76,651Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Aug 6, 2022 19:1576,01949,183,90526,118,0002,009,0002,281,472
2Aug 6, 2022 19:1576,27350,943,15225,198,0003,023,0002,527,232
3Aug 6, 2022 19:1576,30049,403,40626,215,0002,016,0002,273,280
4Aug 6, 2022 19:1576,32749,632,56126,224,0002,017,0002,371,584
5Aug 6, 2022 19:1576,36855,303,00825,229,0003,027,0002,527,232
6Aug 6, 2022 19:1576,61652,628,49026,324,0002,024,0002,281,472
7Aug 6, 2022 19:1576,65150,781,74526,336,0002,025,0002,281,472
8Aug 6, 2022 19:1576,85453,451,60026,405,0002,031,0002,277,376
9Aug 6, 2022 19:1577,03051,536,02627,484,0001,017,0002,527,232
10Aug 6, 2022 19:1580,506102,277,88329,787,39502,260,992
11Aug 6, 2022 19:1581,15299,142,40430,026,09702,260,992
12Aug 6, 2022 19:1581,30985,248,95330,084,39102,244,608