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 22:42Franek KortaFranek KortaError
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 22:4200000Error: expected "429496491208 ", got "429496489074"stderr
2Sep 2, 2023 22:4300000Error: expected "429496521977 ", got "429496521798"stderr
3Sep 2, 2023 22:4600000Error: expected "429496478323 ", got "429496476427"stderr
4Sep 2, 2023 22:4264,96684,253,47424,037,51302,289,664
5Sep 2, 2023 22:4265,11489,423,53924,092,10102,289,664
6Sep 2, 2023 22:4265,24896,855,57524,141,87102,297,856