#include <bits/stdc++.h>

using namespace std;

typedef long long i64;
typedef pair<int,int> pii;
const int N = 1e5+10;
int n, A, B, sum, a[N], b[N], tot;
pii tmp[N];

signed main() {
	cin >> n >> A >> B; sum = B;
	for(int i = 1; i <= n; i ++) {
		scanf("%d", &a[i]);
		b[i] = 1ll * a[i] * B / A;
		sum -= b[i];
		if(1ll * a[i] * B % A)
			tmp[++tot] = pii(1ll * a[i] * B % A, i);
	}
	sort(tmp + 1, tmp + 1 + tot);
	while(sum) {
		int p = tmp[tot].second;
		b[p] ++; sum --, tot --;
	}
	for(int i = 1; i <= n; i ++) printf("%d ", b[i]), sum += b[i];
	assert(sum == B);
	return 0;
}
#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for(int i=0; i<(int)(n); i++)
#define rep1(i, n) for(int i=1; i<=(int)(n); i++)
#define rep2(i, n, m) for(int i=(int)n; i<=(int)m; i++)
typedef long long ll;
typedef vector<int> vi;
typedef vector<vi> wi;
typedef vector<ll> vl;
typedef vector<vl> wl;
const ll inf=1LL<<60;
const ll mod=1000000007;

int main(){
  cin.tie(0);
  ios::sync_with_stdio(false);

  int n, m, t;
  cin >> n >> m >> t;
  vi a(m), b(m);
  rep(i, m)cin >> a[i] >> b[i];

  int bt=n, f=0, e=0;
  rep(i, m){
  	bt-=a[i]-e;
  	if(bt<=0){
  		f=1;
  		break;
  	}
  	bt+=b[i]-a[i];
  	bt=min(n, bt);
  	e=b[i];
  }

  if(f==0&&bt-(t-e)>0)cout << "Yes\n";
  else cout << "No\n";

  return 0;
}