#include <bits/stdc++.h>
using namespace std;
int n;
int w[25], a[25];
int g;
bool dfs(int s, int state) {
  if (s == g) return true;
  for (int i = 0; i < n; ++i) {
    if ((state & (1 << i)) == 0 && s + w[i] <= a[i]) {
      if (dfs(s + w[i], state | (1 << i))) {
        return true;
      }
    }
  }
  return false;
}
int main() {
  while (cin >> n && n) {
    g = 0;
    for (int i = 0; i < n; ++i) {
      cin >> w[i] >> a[i];
      g += w[i];
    }
    cout << (dfs(0, 0) ? "Yes" : "No") << endl;
  }
  return 0;
}
