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 listJul 6, 2025 09:52Aniruddha DebAniruddha DebScore: 5,803Success
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Jul 6, 2025 09:525,66364,124,64546,435,00002,342,912
2Jul 6, 2025 09:525,74475,344,38544,097,0003,006,0002,326,528
3Jul 6, 2025 09:525,75573,653,78443,176,0004,016,0002,461,696
4Jul 6, 2025 09:525,77970,824,20047,385,00002,330,624
5Jul 6, 2025 09:525,80381,181,31647,584,00002,322,432
6Jul 6, 2025 09:525,85271,221,99545,991,0001,999,0002,301,952
7Jul 6, 2025 09:525,87571,511,57646,165,0002,007,0002,473,984
8Jul 6, 2025 09:526,04979,681,97649,604,00002,461,696
9Jul 6, 2025 09:526,07779,512,04147,836,0001,993,0002,351,104