fun main(args: Array<String>) {
    keyence2020b()
}

fun keyence2020b() {
    val n = readLine()!!.toInt()
    val xlList = (1..n)
        .map { readLine()!!.split(' ').map { it.toLong() }.let { Pair(it[0] - it[1], it[0] + it[1]) } }

    val sorted = xlList.sortedBy { it.second }

    var answer = 0L
    var currLeft = Long.MIN_VALUE

    for (i in 0 until n) {
        val xl = sorted[i]
        if (currLeft <= xl.first) {
            answer++
            currLeft = xl.second
        }
    }

    println(answer)
}
