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, 2022 01:28Kenneth MaplesKenneth MaplesError
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, 2022 01:2700000Error: expected "2298504020 ", got "-1 "
2Oct 12, 2022 01:2828,717294,420,483235,483,46102,273,280
3Oct 12, 2022 01:2832,503343,503,851266,522,81002,191,360
4Oct 12, 2022 01:2833,758342,973,741276,819,56802,277,376