#include <cstdio>
#include <cstdlib>
#include <cmath>
#include <climits>
#include <cfloat>
#include <map>
#include <utility>
#include <set>
#include <iostream>
#include <memory>
#include <string>
#include <vector>
#include <algorithm>
#include <functional>
#include <sstream>
#include <complex>
#include <stack>
#include <queue>
#include <cstring>
#include <climits>
using namespace std;
static const double EPS = 1e-5;
typedef long long ll;


int main(){
	int n;
	while(cin>>n){
		if(n==0)break;
		double minabs=INT_MAX;
		
		double len,wei,num,minnum;
		while(n--){
			cin>>num>>len>>wei;
			double dbmi=abs(22.0-wei/len/len*100*100);
			if(dbmi<minabs){
				minnum=num;
				minabs=dbmi;
			}
		}
		cout<<minnum<<endl;
	}
}