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 listSep 2, 2023 21:50Franek KortaFranek KortaScore: 61,784Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 2, 2023 21:5061,25747,782,76722,665,00002,269,184
2Sep 2, 2023 21:5061,26847,450,12722,669,00002,437,120
3Sep 2, 2023 21:5061,29546,157,78122,679,00002,449,408
4Sep 2, 2023 21:5061,39748,164,73622,717,00002,523,136
5Sep 2, 2023 21:5061,78148,366,88221,866,000993,0002,527,232
6Sep 2, 2023 21:5061,78145,146,55520,872,0001,987,0002,445,312
7Sep 2, 2023 21:5061,78444,842,32121,821,0001,039,0002,441,216
8Sep 2, 2023 21:5061,80346,065,54921,873,000994,0002,531,328
9Sep 2, 2023 21:5061,81456,588,22621,877,000994,0002,269,184
10Sep 2, 2023 21:5065,30885,151,88624,163,97602,179,072
11Sep 2, 2023 21:5065,335105,465,07424,173,98402,289,664
12Sep 2, 2023 21:5065,567106,055,82624,259,87002,293,760