#include<bits/stdc++.h>
using namespace std;
#define rep(x,y,z) for(int x=(y);(x)<(z);x++)
const int maxn=1e4;
int m,n,s;
double a[maxn];
int main(){
cin>>n;
rep(i,0,n) cin>>a[i];
sort(a,a+n);
rep(i,0,n-1){
a[i+1]=(a[i+1]+a[i])/2;
}
cout<<(int)a[n-1]<<"\n";
return 0;
}