#include <iostream>
#include <fstream>

using namespace std;

int main() {
    freopen("petrol.in", "r", stdin);
    freopen("petrol.out", "w", stdout);
    int n;
    scanf("%d", &n);
    int best = -1;
    double gas = 1e9;
    for (int i = 0; i < n; i++) {
        int a, b, c;
        scanf("%d%d%d", &a, &b, &c);
        if ((double)a / (c - b) < gas) {
            best = i;
            gas = (double)a / (c - b);
        }
    }
    cout << best + 1;
    return 0;

}