Little Susie listens to fairy tales before bed every day. Today's fairy tale was about wood cutters and the little girl immediately started imagining the choppers cutting wood. She imagined the situation that is described below.

There are *n* trees located along the road at points with coordinates *x*<sub class="lower-index">1</sub>, *x*<sub class="lower-index">2</sub>, ..., *x*<sub class="lower-index">*n*</sub>. Each tree has its height *h*<sub class="lower-index">*i*</sub>. Woodcutters can cut down a tree and fell it to the left or to the right. After that it occupies one of the segments [*x*<sub class="lower-index">*i*</sub> - *h*<sub class="lower-index">*i*</sub>, *x*<sub class="lower-index">*i*</sub>] or [*x*<sub class="lower-index">*i*</sub>;*x*<sub class="lower-index">*i*</sub> + *h*<sub class="lower-index">*i*</sub>]. The tree that is not cut down occupies a single point with coordinate *x*<sub class="lower-index">*i*</sub>. Woodcutters can fell a tree if the segment to be occupied by the fallen tree doesn't contain any occupied point. The woodcutters want to process as many trees as possible, so Susie wonders, what is the maximum number of trees to fell.
The first line contains integer *n* (1 ≤ *n* ≤ 10<sup class="upper-index">5</sup>) — the number of trees.

Next *n* lines contain pairs of integers *x*<sub class="lower-index">*i*</sub>, *h*<sub class="lower-index">*i*</sub> (1 ≤ *x*<sub class="lower-index">*i*</sub>, *h*<sub class="lower-index">*i*</sub> ≤ 10<sup class="upper-index">9</sup>) — the coordinate and the height of the *і*-th tree.

The pairs are given in the order of ascending *x*<sub class="lower-index">*i*</sub>. No two trees are located at the point with the same coordinate.
n=int(input())
l=[[0]for i in range(n)]
for i in range(n):
    l[i]=list(map(int,input().split()))#将树位置和长度存入列表
s=2 #第一棵树往左倒，最后一棵树往右倒，所以至少有两棵树，它们两个的位置就是中间的倒地区间
for i in range(1,n-1):#从第二棵树和倒数第二棵树开始计算
    x,h=l[i] #取出树的位置和长度，非必要
    if x-h>l[i-1][0]:
        s+=1 #首先考虑往左倒，不砸到前面的树即可
    elif x+h<l[i+1][0]:
        s+=1 #其次再考虑向右倒，不砸到后面的树即可
        l[i][0]+=h #把树顶作为新的位置，不用考虑两棵树一棵倒了影响另外一棵，因为计得是棵数，而且一棵树至多对其周围的两棵树有影响
if n>1:
    print(s)
else:
    print(1) #排除只有一棵树的特殊情况