struct data
{
int luna;
int an;
}v[100];
int main()
{
int n, s1=0, s2=0;
cin>>n;
for(int i=0;i<n;i++)
{
cin>>v[i].luna>>v[i].an;
s1=v[i].an+s1;
s2=v[i].luna+s2;
}
cout<<"Varsta medie "<<s1/n<<"."<<s2/n;
for(int i=0; i<n; i++)
if(v[i].an<=s1/n && v[i].luna<=s2/n)
cout<<v[i].an<<"."<<v[i].luna<<endl;
}