#include<iostream>
#include<algorithm>
#include<vector>
#include<string>
using namespace std;

typedef long long ll;
typedef vector <ll> v_ll;
typedef vector <vector <ll> > vv_ll;
typedef vector < pair <ll,ll> > vp_ll;
typedef pair <ll,ll> p_ll;

bool TEST=false;
ll MOD = 1000000007;

void show(){if (TEST){cout << endl;}}
void show(string x){if (TEST){cout << x;}}
void show(string x,bool enter){
  if (TEST){if (enter) cout << "<#> " << x << endl;else cout << x;}
}
void show(ll x){if (TEST){cout << x;}}
void show(ll x,bool enter){
  if (TEST){if (enter) cout << "<#> " << x << endl;else cout << x;}
}
void show(p_ll p){
  if (TEST){cout << "{ ";show(p.first);cout << " ";show(p.second);cout << " }";}
}
void show(v_ll v){
  if (TEST){
    cout << "<begin> ";
    for (ll i=0;i<v.size();i++){show(v[i]); cout << " ";}cout <<"<end>"<< endl;
}}
void show(vv_ll v){
  if (TEST){
    cout << "//////////" << endl;
    for (ll i=0;i<v.size();i++){
      show(v[i]); cout << endl;
}}}
void show(vp_ll v){
  if (TEST){
    cout << "//////////" << endl;
    for (ll i=0;i<v.size();i++){
      show(v[i]); cout << endl;
}}}

ll mod(ll x){
  ll n=MOD;
  ll ret=x%n;
  if (ret<0)ret+=n;
  return ret;
}
void mod_self(ll &x){
  x=mod(x);
}
ll mod_inv(ll x){
  ll n=MOD;
  ll y = x,z = n-2, ret=1;
  y=mod(y);
  while (z>0){
    if(z%2==1) ret=mod(ret*y);
    y=mod(y*y);
    z/=2;
  }
  return ret;
}
ll mod_pow(ll x,ll a){
  ll y = x,z = a,ret=1;
  y=mod(y);
  if (z<0)z=-z;
  while (z>0){
    if(z%2==1) ret=mod(ret*y);
    y=mod(y*y);
    z/=2;
  }
  if (a<0) ret=mod_inv(ret);
  return ret;
}
v_ll mod_nck(ll n){
  v_ll nck(n+1,0);
  nck[0]=1;
  for (ll i=1;i<=n;i++){
    nck[i]=mod(nck[i-1]*(n+1-i));
    nck[i]=mod(nck[i]*mod_inv(i));
  }
  return nck;
}
v_ll mod_factorial(ll n){
  v_ll fct(n+1,0);
  fct[0]=1;
  for (ll i=1;i<=n;i++){
    fct[i]=mod(fct[i-1]*i);
  }
  return fct;
}

//comparison for pair
bool comp_f_ls(const p_ll &x,const p_ll &y){
  if (x.first<y.first)return true;
  if (x.first>y.first)return false;
  if (x.second<y.second)return true;
  if (x.second>y.second)return false;
  return false;
}

//comparison for pair
bool comp_s_ls(const p_ll &x,const p_ll &y){
  if (x.second<y.second)return true;
  if (x.second>y.second)return false;
  if (x.first<y.first)return true;
  if (x.first>y.first)return false;
  return false;
}

//comparison for pair
bool comp_f_gr(const p_ll &x,const p_ll &y){
  return comp_f_ls(y,x);
}

//comparison for pair
bool comp_s_gr(const p_ll &x,const p_ll &y){
  return comp_s_ls(y,x);
}





ll N;
vp_ll A;
ll dead_line;


//comparison for pair
bool comp(const p_ll &y,const p_ll &x){
  if (x.second>=dead_line && y.second>=dead_line){

  }else{
    if (x.second<y.second)return true;
    if (x.second>y.second)return false;
  }
  if (x.first<y.first)return true;
  if (x.first>y.first)return false;
  return false;
}

int main(){
  cin >> N;
  dead_line=100000000000;
  A.assign(N+10,make_pair(0,0));
  for (ll i=1;i<=N;i++){
    cin >> A[i].first >> A[i].second;
  }

  sort(A.begin()+1,A.begin()+N+1,comp_s_ls);
  ll fin=0;
  ll idx;
  for (ll i=1;i<=N;i++){
    if (A[i].first+fin<=A[i].second){
      fin+=A[i].first;
    }else{
      cout << "No" << endl;
      return 0;
    }
  }
  cout << "Yes" << endl;
}


Measured memory_bytes: 3328