"use strict";
const main = arg => {
  let Nums = arg.split("\n");
  let NumArr = Nums[1].split(" ").map(x=> x*1).sort((a, b) => a - b);
  let ans = 0;
  let temp = 0;
  if(NumArr.length == 2){
    ans = (NumArr[0] + NumArr[1])/2;
  } else {
    for(let i = 2; i < Nums[0]; i++){
      temp = (NumArr[i-2] + NumArr[i - 1])/2
      ans = (temp + NumArr[i])/2
    }
  }
  console.log(ans);
}

main(require('fs').readFileSync('/dev/stdin', 'utf8'));
