#include <bits/stdc++.h>
using namespace std;
bool check(long long n, long long pos) { return n & (1LL << pos); }
long long Set(long long n, long long pos) { return n = n | (1LL << pos); }
pair<long long, long long> arr[200];
int main() {
  long long i, j, k, l, m, n, o, r, q;
  long long testcase;
  long long input, flag, tag, ans;
  scanf("%lld", &n);
  for (long long cs = 1; cs <= n; cs++) {
    scanf("%lld", &arr[cs].first);
    scanf("%lld", &arr[cs].second);
  }
  for (i = 1; i <= n; i++) {
    input = arr[i].first + arr[i].second;
    for (j = 1; j <= n; j++) {
      if (i != j)
        if (arr[j].first == input)
          if (arr[j].first + arr[j].second == arr[i].first) {
            cout << "YES" << endl;
            return 0;
          }
    }
  }
  cout << "NO" << endl;
}
