#include <bits/stdc++.h>
using namespace std;
pair<int, int> D[1000000];
int state[1000000];
int n, mx = 0;
int main() {
  scanf("%d", &n);
  for (int i = 0, size = 0; i < n; ++i, size += 2) {
    int x, w;
    scanf("%d%d", &x, &w);
    D[size].first = x - w;
    D[size].second = i + 1;
    D[size + 1].first = x + w;
    D[size + 1].second = -i - 1;
  }
  sort(D, D + 2 * n);
  for (int i = 0; i < n * 2; ++i) {
    if (D[i].second < 0)
      mx = max(mx, state[-D[i].second]);
    else
      state[D[i].second] = mx + 1;
  }
  printf("%d\n", mx);
  return 0;
}
