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 listNov 7, 2024 15:52Matt StuchlikMatt StuchlikError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Nov 7, 2024 15:5200000Error: Exit with code 1: Index out of bounds: 5289684stderr
2Nov 7, 2024 15:5300000Error: Exit with code 1: Index out of bounds: 8651809stderr
3Nov 7, 2024 15:5380,976694,423,579645,000,00019,000,0002,285,568
4Nov 7, 2024 15:5284,307719,808,750669,336,00021,978,0002,473,984
5Nov 7, 2024 15:5384,885721,174,539681,058,00015,001,0002,297,856
6Nov 7, 2024 15:5385,304727,717,494684,502,00014,989,0002,400,256
7Nov 7, 2024 15:5285,340728,176,997673,794,00025,992,0002,428,928
8Nov 7, 2024 15:5291,457779,468,940730,952,00018,998,0002,285,568