#include <bits/stdc++.h>
using namespace std;
int dx[] = {-1, -1, -1, 0, 0, 1, 1, 1};
int dy[] = {-1, 0, 1, -1, 1, -1, 0, 1};
double PI = 3.1415926535897932384626433832795;
int a[11], mod[11], b[100001];
string ans, anss;
void fill(int mn, int x, int y) {
  mod[x] -= mn;
  mod[y] -= mn;
  for (int i = 0; i < mn; i++) {
    ans += x + '0';
    ans += y + '0';
  }
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  int x[1005], d[1005], b[1005], n;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> x[i] >> d[i];
    b[i] = x[i] + d[i];
  }
  for (int i = 0; i < n; i++) {
    for (int j = i; j < n; j++) {
      if (b[i] == x[j] && b[j] == x[i]) {
        cout << "YES";
        return 0;
      }
    }
  }
  cout << "NO";
  return 0;
}
