#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, answer = 0;
  cin >> n;
  int arr[n][2], range[n];
  for (int r = 0; r < n; r++) {
    cin >> arr[r][0] >> arr[r][1];
  }
  for (int r = 0; r < n; r++) {
    range[r] = arr[r][0] + arr[r][1];
  }
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      if (arr[j][0] == range[i]) {
        if (arr[i][0] == range[j]) {
          answer++;
        }
      }
    }
  }
  if (answer > 0) {
    cout << "YES";
  } else {
    cout << "NO";
  }
  return 0;
}
