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:02Pavel 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:030130,822,289110,416,0002,007,0002,416,640expected "2116968780 ", got "2131314551 "
2May 1, 2026 17:0313,711125,979,602111,430,0001,003,0002,326,528
3May 1, 2026 17:0313,714126,717,473111,458,0001,004,0002,412,544
4May 1, 2026 17:0313,724129,994,316111,538,0001,004,0002,387,968
5May 1, 2026 17:0313,735131,161,563110,616,0002,011,0002,326,528
6May 1, 2026 17:0313,760133,272,673110,838,0001,997,0002,326,528
7May 1, 2026 17:0313,768131,967,286110,905,0001,998,0002,416,640
8May 1, 2026 17:0313,773127,591,624110,943,0001,998,0002,404,352
9May 1, 2026 17:0313,782128,474,900111,015,0002,000,0002,412,544