#include <bits/stdc++.h>
using namespace std;
int dx[] = {-1, 1, 0, 0};
int dy[] = {0, 0, -1, 1};
int n, a[101], d[101];
int main() {
  cin >> n;
  for (int i = 1; i <= n; i++) cin >> a[i] >> d[i];
  bool res = false;
  for (int i = 1; i <= n; i++) {
    if (res) break;
    for (int j = i + 1; j <= n; j++)
      if (a[i] + d[i] == a[j] && a[j] + d[j] == a[i]) {
        res = true;
        break;
      }
  }
  printf(res ? "YES" : "NO");
  return 0;
}
