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:57Pavel 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:580117,284,725100,662,0003,986,0002,318,336expected "2196044014 ", got "2240732912 "
2May 1, 2026 17:5812,736121,624,402102,432,0002,008,0002,420,736
3May 1, 2026 17:5812,739121,990,800101,451,0003,013,0002,433,024
4May 1, 2026 17:5812,757118,530,468102,601,0002,011,0002,420,736
5May 1, 2026 17:5812,760119,633,485101,651,0002,989,0002,326,528
6May 1, 2026 17:5812,764126,491,829102,672,0001,993,0002,433,024
7May 1, 2026 17:5812,789121,123,849102,873,0001,997,0002,433,024
8May 1, 2026 17:5812,801124,102,831102,956,0002,018,0002,428,928
9May 1, 2026 17:5812,838118,497,965104,264,0001,012,0002,326,528