N = int(eval(input()))



ST = []

for _ in range(N):

    x, l = list(map(int, input().split()))

    ST.append((x-l, x+l))



ST.sort(key=lambda x: x[1])



ans = 0

cur = -1e9

for i in range(N):

    s, t = ST[i]

    if cur <= s:

        ans += 1

        cur = t

print(ans)

import sys





def input():

    return sys.stdin.readline()[:-1]





N = int(eval(input()))



XL = []

for _ in range(N):

    x, l = list(map(int, input().split()))

    XL.append((x-l, x+l))



XL.sort(key=lambda x: x[1])



ans = 0

cur = -1e9

for i in range(N):

    if cur <= XL[i][0]:

        ans += 1

        cur = XL[i][1]

print(ans)

N = int(eval(input()))
ST = []
for _ in range(N):
    x, l = list(map(int, input().split()))
    ST.append((x - l, x + l))
ST.sort(key=lambda x: x[1])
ans = 0
cur = -1e9
for i in range(N):
    s, t = ST[i]
    if cur <= s:
        ans += 1
        cur = t
print(ans)

import sys


def input():
    return sys.stdin.readline()[:-1]


N = int(eval(input()))
XL = []
for _ in range(N):
    x, l = list(map(int, input().split()))
    XL.append((x - l, x + l))
XL.sort(key=lambda x: x[1])
ans = 0
cur = -1e9
for i in range(N):
    if cur <= XL[i][0]:
        ans += 1
        cur = XL[i][1]
print(ans)

+import sys + + +def input(): +    return sys.stdin.readline()[:-1] + + -ST = [] +XL = [] -    ST.append((x - l, x + l)) -ST.sort(key=lambda x: x[1]) +    XL.append((x - l, x + l)) +XL.sort(key=lambda x: x[1]) -    s, t = ST[i] -    if cur <= s: +    if cur <= XL[i][0]: -        cur = t +        cur = XL[i][1]