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