#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<double> v;
  for (int i = 0; i < n; i++) {
    double x;
    cin >> x;
    v.push_back(x);
  }
  while (v.size() != 1) {
    double x = v.back();
    v.pop_back();
    double y = v.back();
    v.pop_back();
    double material = (x + y) / 2.0;
    int i = v.size() - 1;
    while (material > v[i]) {
      i--;
    }
    v.push_back(material);
  }
  cout << v[0] << endl;
  return 0;
}
