MEDIAN

MEDIAN(x) or MED(x) finds the median of the values in x.