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 listNov 28, 2024 20:07Joad NacerJoad NacerError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Nov 28, 2024 20:0600000Error: expected "429496444263 ", got "386546821758 "stderr
2Nov 28, 2024 20:0600000Error: expected "429496456423 ", got "399431721238 "stderr
3Nov 28, 2024 20:0700000Error: expected "429496501116 ", got "429496496635 "stderr
4Nov 28, 2024 20:0759,26243,387,41220,931,000996,0002,428,928
5Nov 28, 2024 20:0759,41444,726,97320,984,000999,0002,531,328
6Nov 28, 2024 20:0761,77356,965,89220,869,0001,987,0002,531,328