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 13, 2024 22:11zielajzielajError
Source Code

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

Challenge History

No challenges yet.

Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Oct 13, 2024 22:1000000Error: expected "2176046085 ", got "2147541023 "stderr
2Oct 13, 2024 22:11343,3372,848,291,5232,797,401,00017,964,0002,379,776
3Oct 13, 2024 22:11344,0762,852,488,0882,803,464,00017,958,0002,363,392
4Oct 13, 2024 22:11344,5302,857,090,7982,806,193,00018,954,0002,351,104