#include <bits/stdc++.h>
using namespace std;
struct p{
	int x,y;
};
int cmp(p a,p b){
	return a.y<b.y;
}
int main(){
	int n;
	cin>>n;
	p a[n+1];
	for(int i=1;i<=n;i++){
		cin>>a[i].x>>a[i].y;
	}
	sort(a+1,a+n+1,cmp);
	int t=0;
	for(int i=1;i<=n;i++){
		t+=a[i].x;
		if(t>a[i].y){
			cout<<"No"<<endl;
			return 0;
		}
	}
	cout<<"Yes"<<endl;
	return 0;
}
