#include <bits/stdc++.h>
using namespace std;
int a[100002];
char s[100002];
int main() {
  int i, n, x, y, flag = 0;
  scanf("%d", &n, x, y);
  while (n--) {
    scanf("%s", s);
    scanf("%d %d", &x, &y);
    if (x >= 2400 && y > x) flag = 1;
  }
  if (flag == 1)
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
  return 0;
}
