Median Sergey Svistunov

Find the median of 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 median value, printed as a decimal string. The median is defined as the element at index N/2 (i.e., a[50000000]) in the sorted array.

Back to listMay 1, 2026 17:06Pavel SkripkinPavel SkripkinError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1May 1, 2026 17:070120,576,54896,860,0003,994,0002,416,640expected "2182581164 ", got "2207001791 "
2May 1, 2026 17:0712,235114,821,47598,322,0002,006,0002,416,640
3May 1, 2026 17:0712,243115,939,52098,387,0002,007,0002,416,640
4May 1, 2026 17:0712,245113,645,15999,400,0001,014,0002,424,832
5May 1, 2026 17:0712,259114,428,12998,515,0002,010,0002,416,640
6May 1, 2026 17:0712,264118,983,64798,554,0002,011,0002,424,832
7May 1, 2026 17:0712,265116,717,78399,570,0001,005,0002,420,736
8May 1, 2026 17:0712,270120,745,80999,608,0001,006,0002,420,736
9May 1, 2026 17:0712,306118,233,63097,917,0002,997,0002,420,736