#include <bits/stdc++.h>
using namespace std;
using ll=long long;
typedef pair<int,int>P;
 
int main() {
  int a;
  cin>>a;
  vector<P>p(a);
  for(int i=0;i<a;i++){
    cin>>p[i].second>>p[i].first;
  }
  sort(p.begin(),p.end());
  ll t=0,tri=0;
  for(int i=0;i<a;i++){
    t+=p[i].second;
    if(t>p[i].first){
      cout<<"No"<<endl;
      tri++;
      break;
    }
  }
  if(tri<1){
  cout<<"Yes"<<endl;
}
}