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