find the median of input number in a list and print

Solutions on MaxInterview for find the median of input number in a list and print by the best coders in the world

showing results for - "find the median of input number in a list and print"
Lisa
04 Jan 2017
1import statistics
2array = []
3n = int(input())
4for _ in range(n):
5    array.append(int(input()))
6print (int(statistics.median(array)))
7