#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c, d, t, arr[1005], x = 1;
  cin >> t;
  for (int j = 0; j < t; j++) {
    cin >> a >> b >> c >> d;
    arr[j] = a + b + c + d;
  }
  for (int i = 1; i < t; i++) {
    if (arr[0] < arr[i]) {
      x++;
    }
  }
  cout << x << endl;
  return 0;
}
