#include<iostream>
#include<cmath>
#define INF 1000000
using namespace std;

int main() {
	int n;
	while (cin >> n, n) {		
		int aa;
		long double sa = INF;

		for (int i = 0;i < n;i++) {
			long double a, b, c;
			cin >> a >> b >> c;
		long double bmi = c / (b*b / 10000);

			if (sa > abs(22 - bmi)) {
				aa = a;
				sa = abs(22 - bmi);
			}
		}

		cout << aa << endl;
	}
	return 0;
}