#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, i, j, f;
  cin >> n;
  int x[n], d[n], c[n];
  f = 0;
  for (i = 0; i < n; i++) {
    cin >> x[i] >> d[i];
    c[i] = x[i] + d[i];
  }
  for (i = 0; i < n; i++) {
    for (j = 0; j < n; j++) {
      if (c[i] == x[j] && c[j] == x[i]) f = f + 1;
    }
    if (f > 0) {
      cout << "YES";
      break;
    }
  }
  if (f == 0) cout << "NO";
  return 0;
}
