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 listApr 9, 2023 16:36Franek KortaFranek KortaScore: 121,149Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Apr 9, 2023 16:36112,37066,753,72841,577,00002,269,184
2Apr 9, 2023 16:36112,67071,604,60438,638,0003,050,0002,527,232
3Apr 9, 2023 16:36114,97363,834,00842,540,00002,265,088
4Apr 9, 2023 16:36116,92466,447,60242,256,0001,006,0002,433,024
5Apr 9, 2023 16:36117,72774,247,65442,546,0001,013,0002,531,328
6Apr 9, 2023 16:36120,31162,298,73144,515,00002,531,328
7Apr 9, 2023 16:36121,14974,334,43842,833,0001,992,0002,269,184
8Apr 9, 2023 16:36121,61168,299,74042,997,0001,999,0002,269,184
9Apr 9, 2023 16:36124,12273,225,51344,927,000998,0002,441,216
10Apr 9, 2023 16:36131,461114,169,26948,640,62102,183,168
11Apr 9, 2023 16:36132,954135,585,07449,192,88402,297,856
12Apr 9, 2023 16:36134,420110,936,95949,735,26802,170,880