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 7, 2023 02:06Yuriy LyfenkoYuriy LyfenkoError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1May 7, 2023 02:0600000Error: expected "2220739121 ", got "2147483648 "stderr
2May 7, 2023 02:065,405610,189,50044,321,05602,224,128
3May 7, 2023 02:065,418600,597,18944,431,04202,297,856
4May 7, 2023 02:065,701609,580,74146,750,80302,260,992