#include<iostream>
#include<algorithm>
#include<vector>
#include<string>
#include<map>
#define rep(i, start, end) for (int i = (int)start; i < (int)end; ++i)
#define rrep(i, start, end) for (int i = (int)start - 1; i >= end; --i)
#define iter(i, c) for (auto i = (c).begin(); i != (c).end(); ++i)
#define riter(i, c) for (auto i = (c).rbegin(); i != (c).rend(); ++i)
#define all(x) (x).begin(), (x).end()
#define rall(x) (x).rbegin(), (x).rend()
using namespace std;
using ll = long long;
template<typename T> inline bool chmax(T& a, T b) {if (a < b) {a = b; return true;} return 0;}
template<typename T> inline bool chmin(T& a, T b) {if (a > b) {a = b; return true;} return 0;}

struct monster {
    ll pos_, hp_;
    monster(ll pos, ll hp):pos_(pos), hp_(hp) {}
    bool operator<(const monster& m)  {
        return pos_ < m.pos_;
    }
};

struct LazySegmentTree {
private:
    int n;
    vector<ll> node, lazy;

public:
    LazySegmentTree(vector<ll> v) {
        int sz = (int)v.size();
        n = 1; while(n < sz) n *= 2;
        node.resize(2*n-1);
        lazy.resize(2*n-1, 0);

        for(int i=0; i<sz; i++) node[i+n-1] = v[i];
        for(int i=n-2; i>=0; i--) node[i] = node[i*2+1] + node[i*2+2];
    }

    void eval(int k, int l, int r) {
        if(lazy[k] != 0) {
            node[k] += lazy[k];
            if(r - l > 1) {
                lazy[2*k+1] += lazy[k] / 2;
                lazy[2*k+2] += lazy[k] / 2;
            }
            lazy[k] = 0;
        }
    }

    void add(int a, int b, ll x, int k=0, int l=0, int r=-1) {
        if(r < 0) r = n;
        eval(k, l, r);
        if(b <= l || r <= a) return;
        if(a <= l && r <= b) {
            lazy[k] += (r - l) * x;
            eval(k, l, r);
        }
        else {
            add(a, b, x, 2*k+1, l, (l+r)/2);
            add(a, b, x, 2*k+2, (l+r)/2, r);
            node[k] = node[2*k+1] + node[2*k+2];
        }
    }

    ll getsum(int a, int b, int k=0, int l=0, int r=-1) {
        if(r < 0) r = n;
        eval(k, l, r);
        if(b <= l || r <= a) return 0;
        if(a <= l && r <= b) return node[k];
        ll vl = getsum(a, b, 2*k+1, l, (l+r)/2);
        ll vr = getsum(a, b, 2*k+2, (l+r)/2, r);
        return vl + vr;
    }
};

int main() {
    cin.tie(0);
    ios::sync_with_stdio(false);
    ll N, D, A;
    cin >> N >> D >> A;
    vector<ll> X(N), H(N);
    rep(i, 0, N) {
        cin >> X[i] >> H[i];
    }
    vector<monster> m;
    rep(i, 0, N) {
        m.emplace_back(X[i], H[i]);
    }
    sort(all(m));
    vector<ll> values;
    rep(i, 0, N) {
        values.push_back(X[i]);
        values.push_back(X[i] + 2 * D);
    }
    sort(all(values));
    values.erase(unique(all(values)), values.end());
    int M = (int)values.size();
    map<ll, int> pos_map;
    rep(i, 0, M) {
        pos_map[values[i]] = i;
    }
    vector<ll> initial_v(M, 0);
    rep(i, 0, N) {
        initial_v[pos_map[m[i].pos_]] = m[i].hp_;
    }
    LazySegmentTree seg(initial_v);
    ll ans = 0;
    rep(i, 0, N) {
        int now_pos = pos_map[m[i].pos_];
        ll now_sum = seg.getsum(now_pos, now_pos + 1);
        if (now_sum <= 0) {
            continue;
        }
        ll now_attack_cnt = (now_sum + A - 1) / A;
        ans += now_attack_cnt;
        int next_pos = pos_map[m[i].pos_ + 2 * D];
        seg.add(now_pos, next_pos + 1, -A * now_attack_cnt);
    }
    cout << ans << endl;
    return 0;
}

Measured memory_bytes: 58092