Submit | All submissions | Best solutions | Back to list |
EIUMEDIAN2 - Median |
Given an array of n integers. Find the median of the array.
Input
The first line is an integer n (n<= 10^6)
The second line is an integer n where absolute value of each number is not more than 10^9.
Output
The median of array
Example
Input: 5
7 8 3 1 4
Output: 4
Input:
6
7 8 3 1 4 5
Output:
4.5