#include<bits/stdc++.h>
#define ll long long
using namespace std;

int main(){
	using P = pair<ll,ll>;
	int n;
	ll d;
	ll a;
	scanf("%d%lld%lld",&n,&d,&a);
	d *= 2;
	P monsters[n];
	for(auto &i:monsters){
		scanf("%lld%lld",&i.first,&i.second);
	}
	sort(monsters,monsters+n);

	ll ans = 0;
	ll sum_damage = 0;
	int rp = 0;
	for(auto &i:monsters){
		while(rp<n&&monsters[rp].first<=i.first+d){
			monsters[rp].second += sum_damage;
			++rp;
		}
		ll hp = i.second - sum_damage;
		if(hp>0){
			ll time = (hp + a - 1) / a;
			ans += time;
			sum_damage += time * a;
		}
	}

	printf("%lld\n",ans);

}
