import java.util.*
fun main(args:Array<String>) {
    data class Monster(val x:Long=0L, var hp:Long=0L)
    var (n,d,a) = readLine()!!.split(" ").map { it.toInt() }
    var monster = Array(n){Monster(0,0)}
    /*
    fun createTestSet() {
        n = 200000
        d =  Random.nextInt(1..1000000000)
        a = Random.nextInt(1..1000000000)
        monster = Array(n){Monster(0,0)}
        val s = HashSet<Int>()
        for(i in 0 until n) {
            var x = Random.nextInt(0..1000000000)
            val hp = Random.nextInt(1..1000000000)
            while(s.contains(x)) {
                x = Random.nextInt(1..1000000000)
            }
            s.add(x)
            monster[i] = Monster(x.toLong(), hp.toLong())

        }
    }
     */

    for(i in 0 until n) {
        val (x,h) = readLine()!!.split(" ").map { it.toInt() }
        monster[i] = Monster(x.toLong(), h.toLong())
    }
    monster.sortBy { it.x }
    var answer = 0L
    var acc = 0L
    val q = LinkedList<Pair<Long,Long>>()
    for(i in 0 until n) {
        var (x, h) = monster[i]
        while(q.isNotEmpty() && q.peekFirst()!!.first + d * 2 < x) {
            val p = q.pollFirst()
            acc -= p.second
        }
        h -= acc
        if(h <= 0) continue
        var cnt = h / a //+ min(h%a, 1)
        if((h%a) >= 1) {
            cnt += 1
        }
        q.add(x to  cnt * a)
        acc += cnt * a
        answer += cnt
    }
    println(answer)
    /*
    var nCase = 1000
    repeat(nCase) {
        createTestSet()
    }
     */
    // x 의 범위가 무지막지하게 크다.
    //


}