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 4, 2024 14:21Andrey LikhachevAndrey LikhachevScore: 70,638Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Aug 4, 2024 14:2170,14154,492,78223,956,0001,996,0002,465,792
2Aug 4, 2024 14:2170,18654,411,52223,972,0001,997,0002,367,488
3Aug 4, 2024 14:2170,40356,902,40624,046,0002,003,0002,383,872
4Aug 4, 2024 14:2170,49248,920,02425,079,0001,003,0002,367,488
5Aug 4, 2024 14:2170,58153,552,47325,111,0001,004,0002,289,664
6Aug 4, 2024 14:2170,62249,275,02025,125,0001,005,0002,375,680
7Aug 4, 2024 14:2170,63849,135,88325,131,0001,005,0002,367,488
8Aug 4, 2024 14:2170,64950,345,25524,130,0002,010,0002,289,664
9Aug 4, 2024 14:2170,77653,041,53724,173,0002,014,0002,371,584
10Aug 4, 2024 14:2173,284120,333,31127,115,20902,220,032
11Aug 4, 2024 14:2174,00398,804,32927,381,20602,330,624
12Aug 4, 2024 14:2174,13898,965,88927,430,90402,207,744