4
10 4
15 1
19 3
20 1
 2
1 999999999
1000000000 1000000000
 67
1 1
3 8
4 10
7 8
9 2
10 1
11 5
12 8
13 4
16 6
18 3
19 3
22 5
24 6
27 5
28 3
29 3
30 5
32 5
33 10
34 7
35 8
36 5
41 3
42 2
43 5
46 4
48 4
49 9
52 4
53 9
55 1
56 4
59 7
68 7
69 4
71 9
72 10
74 5
76 4
77 9
80 7
81 9
82 5
83 5
84 9
85 7
86 9
87 4
88 7
89 10
90 3
91 5
92 10
93 5
94 8
95 4
96 2
97 10
98 1
99 3
100 1
101 5
102 4
103 8
104 8
105 8
 10
999999900 1000000000
999999901 1000000000
999999902 1000000000
999999903 1000000000
999999904 1000000000
999999905 1000000000
999999906 1000000000
999999907 1000000000
999999908 1000000000
999999909 1000000000
 35
1 7
3 11
6 12
7 6
8 5
9 11
15 3
16 10
22 2
23 3
25 7
27 3
34 5
35 10
37 3
39 4
40 5
41 1
44 1
47 7
48 11
50 6
52 5
57 2
58 7
60 4
62 1
67 3
68 12
69 8
70 1
71 5
72 5
73 6
74 4
 1
1000000000 1000000000
 2
100000000 1000000000
1000000000 1000000000
 10
7 12
10 2
12 2
15 1
19 2
20 1
53 25
63 10
75 12
87 1
 3
1 1
1000 1000
1000000000 1000000000
 40
1 1
2 1
3 1
4 1
5 1
6 1
7 1
8 1
9 1
10 1
11 1
12 1
13 1
14 1
15 1
16 1
17 1
18 1
19 1
20 1
21 1
22 1
23 1
24 1
25 1
26 1
27 1
28 1
29 1
30 1
31 1
32 1
33 1
34 1
35 1
36 1
37 1
38 1
39 1
40 1

4
 2
 5
 2
 10
 1
 2
 9
 3
 2

//package credit;


import javax.swing.plaf.metal.MetalTabbedPaneUI;
import javax.xml.transform.stax.StAXResult;
import java.io.*;
import java.net.CookieHandler;
import java.security.cert.CertificateParsingException;
import java.text.CollationElementIterator;
import java.util.*;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;
import java.util.concurrent.CopyOnWriteArrayList;
import java.util.concurrent.atomic.AtomicReferenceArray;

public class Main {
    static boolean v[];
    static int ans[];
    int size[];
    static int count = 0;
    static int dsu = 0;
    static int c = 0;
    static int e9 = 1000000007;
    int min = 0;
    int max = Integer.MIN_VALUE;
    long max1 = Long.MIN_VALUE;
    long min1 = Long.MAX_VALUE;
    boolean aBoolean = true;
    boolean y = false;
    long m = 0;
    static boolean t1 = false;
    int fib[];
    static class FastReader {
        BufferedReader br;
        StringTokenizer st;

        public FastReader() {
            br = new BufferedReader(new
                    InputStreamReader(System.in));
        }

        String next() {
            while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }

        int nextInt() {
            return Integer.parseInt(next());
        }

        long nextLong() {
            return Long.parseLong(next());
        }

        double nextDouble() {
            return Double.parseDouble(next());
        }

        String nextLine() {
            String str = "";
            try {
                str = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            return str;
        }
    }

    int parent[];
    int rank[];
    int n = 0;
    ArrayList<ArrayList<Integer>> arrayLists;
    boolean v1[];
    static boolean t2 = false;
    boolean r = false;
    long egg[];
    long cb[];
    int min3 = Integer.MAX_VALUE;
    int k = 0;
    Queue<Long> queue;
    HashMap<Long, ArrayList<Long>> hashMap;
    HashMap<Long, Boolean> hashMap1;
    HashMap<Long, Long> hashMap2;
    long p = 0;
    char arr[][];
    public static void main(String[] args) throws IOException {
        Main g = new Main();
        g.go();
    }

    public void go() throws IOException {
        FastReader scanner = new FastReader();
//            Scanner scanner = new Scanner(System.in);
//            BufferedReader bufferedReader=new BufferedReader(new InputStreamReader(System.in));
//            String s;
        PrintWriter printWriter = new PrintWriter(System.out);
        int t=1;
        while (t-- > 0) {
           int n=scanner.nextInt();
           int x[]=new int[n];
           int h[]=new int[n];
            for (int i = 0; i < n; i++) {
                x[i]=scanner.nextInt();
                h[i]=scanner.nextInt();
            }
            int arr[][]=new int[n][3];
            arr[0][0]=0;
            arr[0][1]=1;
            arr[0][2]=1;
            for (int i = 1; i < n; i++) {
                int l=x[i-1];
                int r=x[i-1]+h[i-1];
                if(x[i]>r){
                    arr[i][2]=Math.max(arr[i-1][2],Math.max(arr[i-1][1],arr[i-1][0]))+1;
                    arr[i][0]=Math.max(arr[i-1][2],Math.max(arr[i-1][1],arr[i-1][0]));
                }else{
                    arr[i][2]=Math.max(arr[i-1][1],arr[i-1][0])+1;
                    arr[i][0]= Math.max(arr[i-1][1],arr[i-1][0]);
                }
                if(x[i]-h[i]>r){
                    arr[i][1]=Math.max(arr[i-1][2],Math.max(arr[i-1][1],arr[i-1][0]))+1;
                    arr[i][0]=Math.max(arr[i-1][2],Math.max(arr[i-1][1],arr[i-1][0]));
                }else if(x[i]-h[i]>l){
                    arr[i][1]=Math.max(arr[i-1][1],arr[i-1][0])+1;
                    arr[i][0]= Math.max(arr[i-1][1],arr[i-1][0]);
                }
            }
            printWriter.println(Math.max(arr[n-1][0],Math.max(arr[n-1][1],arr[n-1][2])));
        }
        printWriter.flush();
    }
    static final int mod=1_000_000_007;
    public long mul(long a, long b) {
        return a*b;
    }
    public long fact(int x) {
        long ans=1;
        for (int i=2; i<=x; i++) ans=mul(ans, i);
        return ans;
    }
    public long fastPow(long base, long exp) {
        if (exp==0) return 1;
        long half=fastPow(base, exp/2);
        if (exp%2==0) return mul(half, half);
        return mul(half, mul(half, base));
    }
    public long modInv(long x) {
        return fastPow(x, mod-2);
    }
    public long nCk(int n, int k) {
        return mul(fact(n), mul(modInv(fact(k)), modInv(fact(n-k))));
    }
    public void parent(int n){
        parent=new int[n+1];
        size=new int[n+1];
        rank=new int[n+1];
        for (int i = 0; i <=n; i++) {
            parent[i]=i;
            rank[i]=0;
            size[i]=1;
        }
    }
    public void union(int i,int j){
        int root1=find(i);
        int root2=find(j);
//            if(root1 != root2) {
//                parent[root2] = root1;
////                sz[a] += sz[b];
//            }
        if(root1==root2){
            return;
        }
        if(rank[root1]>rank[root2]){
            parent[root2]=root1;
            size[root1]+=size[root2];
        }
        else if(rank[root1]<rank[root2]){
            parent[root1]=root2;
            size[root2]+=size[root1];
        }
        else{
            parent[root2]=root1;
            rank[root1]+=1;
            size[root1]+=size[root2];
        }
    }
    public int find(int p){
        if(parent[p]!=p){
            if(parent[p]==-1){
                return parent[p];
            }
            parent[p]=find(parent[p]);
        }
        return parent[p];
    }
    public double dist(double x1,double y1,double x2,double y2){
        double e=(x2-x1)*(x2-x1)+(y2-y1)*(y2-y1);
        double e1=Math.sqrt(e);
        return e1;
    }
    public void make(int p){
        parent[p]=p;
        rank[p]=1;
    }
    Random rand = new Random();
    public void sort(int[] a, int n) {
        for (int i = 0; i < n; i++) {
            int j = rand.nextInt(i + 1);
            int tmp = a[i];
            a[i] = a[j];
            a[j] = tmp;
        }
        Arrays.sort(a, 0, n);
    }
    public long gcd(long a,long b){
        if(b==0){
            return a;
        }
        return gcd(b,a%b);
    }
    public void dfs(ArrayList<Integer> arrayList){
        for (int i = 0; i < arrayList.size(); i++) {
            if(v1[arrayList.get(i)]==false){
                v1[arrayList.get(i)]=true;
                dfs(arrayLists.get(i));
            }
        }
    }
    public double fact(double h){
        double sum=1;
        while(h>=1){
            sum=(sum%e9)*(h%e9);
            h--;
        }
        return sum%e9;
    }
    public long primef(double r){
        long c=0;
        long ans=1;
        while(r%2==0){
            c++;
            r=r/2;
        }
        if(c>0){
            ans*=2;
        }
        c=0;
//            System.out.println(ans+" "+r);
        for (int i = 3; i <=Math.sqrt(r) ;i+=2) {
            while(r%i==0){
//                    System.out.println(i);
                c++;
                r=r/i;
            }
            if(c>0){
                ans*=i;
            }
            c=0;
        }
        if(r>2){
            ans*=r;
        }
        return ans;
    }
    public long divisor(double r){
        long c=0;
        for (int i = 1; i <=Math.sqrt(r); i++) {
            if(r%i==0){
                if(r/i==i){
                    c++;
                }
                else{
                    c+=2;
                }
            }
        }
        return c;
    }
}
class Pair {
    long x;
    long y;
    int z;
    public Pair(long x, long y) {
        this.x = x;
        this.y = y;
//        this.z=z;
    }

   // @Override
//    public int hashCode() {
//        int hash = 37;
//        return this.x * hash + this.y;
//    }
//
//    @Override
//    public boolean equals(Object o1) {
//        if (o1 == null || o1.getClass() != this.getClass()) {
//            return false;
//        }
//        Pair o = (Pair) o1;
//        if (o.x == this.x && o.y == this.y) {
//            return true;
//        }
//        return false;
//    }
}
class Sorting implements Comparator<Pair> {
    public int compare(Pair p1, Pair p2) {
//        if(p1.y==p2.y){
//            return Integer.compare(p1.x,p2.x);
//        }else {
            return Integer.compare(p1.z, p2.z);
       // }
    }
}