open System
open System.Collections.Generic

[<AutoOpen>]
module Cin =
    let read f = stdin.ReadLine() |> f
    let reada f = stdin.ReadLine().Split() |> Array.map f
    let readChars() = read string |> Seq.toArray
    let readInts() = readChars() |> Array.map (fun x -> Convert.ToInt32(x.ToString()))

[<AutoOpen>]
module Cout =
    let writer = new IO.StreamWriter(new IO.BufferedStream(Console.OpenStandardOutput()))
    let print (s: string) = writer.Write s
    let println (s: string) = writer.WriteLine s
    let inline puts (s: ^a) = string s |> println

let main() =
    let [| N; D; A |] = reada int
    let A = int64 A
    let D = int64 D
    let xhs = Array.zeroCreate N
    for i in 0 .. N - 1 do
        let [| x; h |] = reada int64
        xhs.[i] <- (x, h)
    let xhs = xhs |> Array.sortBy (fun (x, h) -> x)
    let mutable l = 0
    let cnts = ResizeArray<int64>()
    while l < N do
        let mutable r = l
        let lx = xhs.[l] |> fst
        let lim = lx + 2L * D |> int64
        let mutable nax = xhs.[l] |> snd
        while r < N && xhs.[r]
                       |> fst
                       <= lim do
            nax <- max nax (xhs.[r] |> snd)
            r <- r + 1

        let tmp = (nax + A - 1L) / A
        cnts.Add(tmp)
        // printfn "l: %d, r: %d, tmp: %d" l r tmp
        if l = r then l <- r + 1 else l <- r

    let mutable ans = 0L
    for c in cnts do
        ans <- ans + c
    ans |> puts
    ()

main()
writer.Close()
