#include <iostream>
#include <vector>
#include <algorithm>
#include <string>

using namespace std;

int main(){

	int n;
	long long sum=0;
	while(cin>>n&&n!=0){
		sum=0;
		for(int i = 0; i < n; i++){
			int t;
			cin>>t;
			sum+=t;
		}
		cout<<sum/n<<endl;
	}

	return 0;
}