#include <bits/stdc++.h>
using namespace std;
const int N = 50 + 5;
int a[N];
int main() {
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> a[i];
  }
  sort(a, a + n);
  int t = a[0];
  for (int i = 0; i < n; i++) {
    a[i + 1] = (a[i + 1] + a[i]) / 2;
  }
  cout << a[n - 1] << endl;
  return 0;
}
