#define	_USE_MATH_DEFINES
#include <iostream>
#include <algorithm>
#include <functional>
#include <vector>
#include <cstdio>
#include <cstring>
#include <cmath>
#include <cfloat>
#include <map>
#include <queue>
#include <stack>
#include <list>
#include <string>
#include <set>
using namespace std;
int main(){
	
	int n;
	while(cin>>n,n!=0){
	vector<string> s(n);
	int k=0;
	double best=1000000;
	for(int i=0;i<n;i++){
		double a,b;
		cin>>s[i];
		cin>>a>>b;
		a=a*pow(10,-2);
		double bmi=double(b)/pow(a,2);
		
		if(abs(22-bmi)<best){
			k=i;
			best=abs(22-bmi);
		}
	}
	
	cout<<s[k]<<endl;
	
	}
	
	
}