#include<cstdio>
#include<algorithm>
using namespace std;
#define MAXN 200002
int n,s;
struct node
{
	int a,b;
}x[MAXN];
bool cmp(node x,node y)
{
	return x.b<y.b;
}
int main()
{
	scanf("%d",&n);
	for(int i=1;i<=n;i++)
		scanf("%d%d",&x[i].a,&x[i].b);
	sort(x+1,x+n+1,cmp);
	for(int i=1;i<=n;i++)
		if(s+x[i].a<=x[i].b)
		{
			s+=x[i].a;
		}
		else
		{
			printf("No");
			return 0;
		}
	printf("Yes");
}