#include <bits/stdc++.h>
using namespace std;
struct stud {
  int math, english, history, german;
};
int main() {
  int studentsNumber;
  int theRank = 1;
  cin >> studentsNumber;
  stud students[studentsNumber];
  int sum[studentsNumber];
  for (int i = 0; i < studentsNumber; i++) {
    cin >> students[i].math;
    cin >> students[i].english;
    cin >> students[i].german;
    cin >> students[i].history;
    sum[i] = students[i].math + students[i].history + students[i].german +
             students[i].english;
  }
  for (int i = 0; i < studentsNumber; i++) {
    if (sum[i] > sum[0]) {
      theRank++;
    }
  }
  cout << theRank << endl;
  return 0;
}
