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 16:10highload-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 16:100265,963,082255,506,0001,012,0002,113,536expected "2225804166 ", got "l0vk0va0v30vf0vk0vo0vi0vn0vd0vf0vj0vg0ve0vi0vi0vi0vi0vi0vh0vg0vi0vi0vh0vp0vi0vi0vi0vi0v80ve0vd0vi0vh0vf0vi0vr0vo0vo0v70vi0vb0vb0v80vl0vp0vh0vb0vi0vi0vn0vk0vi0vi0vi0vg0vg0vr0v80vp0vh0vc0ve0ve0v "
2Oct 12, 2026 16:100267,632,377257,668,0001,003,0002,113,536expected "2088020254 ", got "60vm0vh0vk0vi0vi0vn0vh0vh0vg0vk0vh0vg0vf0vh0vs0vj0vi0vh0vh0v80vn0vn0vh0vh0ve0vd0vh0vm0vf0vh0vh0vh0vh0vh0vi0vm0ve0vc0vf0vh0vi0vh0vg0vh0vi0v60ve0vj0vi0vh0vk0vf0vc0vh0vh0vh0vh0vg0vg0vg0vg0vr0vg0v "
3Oct 12, 2026 16:100257,125,184247,077,0001,032,0002,113,536expected "2140160122 ", got "h0vh0vh0vh0vh0vd0va0v60vh0va0vd0vh0vi0vh0vg0vg0vh0vb0vh0vh0vh0vg0vq2un0vq0vh0vj0vy0vj0vf0v60vg0vj0vj0vj0vh0vh0vh0vh0vh0vh0vh0vh0vi0vh0vh0vh0vg0vh0vi0vq0vh0vh0vi0vn0vf0ve0vh0vj0vh0vi0v90vh0vg0v "