import std.algorithm;
import std.array;
import std.container;
import std.conv;
import std.math;
import std.numeric;
import std.range;
import std.stdio;
import std.string;
import std.typecons;

alias Monster = Tuple!(long, "x", long, "h");

long calc(long d, long a, Monster[] ms) {
    ms.sort!"a.x < b.x";

    int lo = 0;
    int hi = 0;
    long ans = 0;
    while (lo < ms.length) {
        if (ms[lo].h <= 0) {
            lo++;
            continue;
        }

        hi = max(hi, lo);
        while (hi+1 < ms.length && ms[hi+1].x - ms[lo].x <= 2 * d) {
            hi++;
        }

        // ms[lo] を倒すのに必要な爆弾の数
        long x = (ms[lo].h + a - 1) / a;
        foreach (i; lo..hi+1) ms[i].h -= x * a;
        ans += x;
        lo++;
    }
    return ans;
}

void main() {
    long n, d, a; scan(n, d, a);
    Monster[] ms;
    foreach (_; 0..n) {
        long x, h; scan(x, h);
        ms ~= Monster(x, h);
    }
    writeln(calc(d, a, ms));
}

void scan(T...)(ref T a) {
    string[] ss = readln.split;
    foreach (i, t; T) a[i] = ss[i].to!t;
}
T read(T=string)() { return readln.chomp.to!T; }
T[] reads(T)() { return readln.split.to!(T[]); }
alias readints = reads!int;
