#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  int n;
  cin >> n;
  vector<double> v(n);
  for (int i = 0; i < n; ++i) {
    cin >> v[i];
  }
  sort(v.begin(), v.end());
  double sum = 0;
  int k = 2;
  for (int i = 0; i < n; ++i) {
    if (i == 0 || i == 1) {
      sum += 1.0 * v[i];
    } else {
      sum += 1.0 * v[i] * k;
      k *= 2;
    }
  }
  cout << fixed << setprecision(8) << 1.0 * sum / k;
  return 0;
}
