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 listOct 12, 2026 15:57highload-churnerhighload-churnerError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Oct 12, 2026 15:580248,735,698239,810,00002,113,536expected "2149243561 ", got "lkhhgfeghmlhhhgghhhikqzohdclkhhihhmngghhhhhlnhikqyg4othhhnwnh30hgdgkihhhhhhhhgfhhhkxskihhh14hhhhhhhdehhha5fhghomhhhhhmi39ijjhhhhhhh60ehhhha0ahsvqncegecfg8agnzohhhhhhb2jtjhiikhd73ce "
2Oct 12, 2026 15:580265,899,896257,071,00002,113,536expected "2168797788 ", got "eehhhhha8ffiihhhhhhhhhhhhhhhhhhhhhhhhhfghhhhhhhhhhhh63hijihhhhhwthijrxkh8ahlrlihhhhhe9ehfehhhmsmhhhhhhikihhhcfnlhhhhhmlhhhhhhhdehfcfhmnhhhiihh40hg9chiihhghhhihhhhhhhhhhhiihhhfdfhhh "
3Oct 12, 2026 15:580261,363,481252,410,00002,113,536expected "2094229963 ", got "bchb3bhprhgefgghhh57gggfeghhjsnhhhgghhhhhhhhhhgga0ahhhghhhhhhtwhkxrhryc7he49hgfghhhhggfforhhghhrzkhhhhhhhhhhhkxqhhhhhhkxqhhhhhhhhhhhhhhwtfhla2ehhhhgefhhhhhhhhhhddkjha0ahhhnmghhhhhh "