#include <bits/stdc++.h>
using namespace std;
vector<pair<long long, long long> > vec;
long long a, b, n;
int main() {
  cin >> n;
  for (int i = 0; i < n; ++i) {
    cin >> a >> b;
    vec.push_back(make_pair(a + b, a - b));
  }
  sort(vec.begin(), vec.end());
  long long ans = 1, taken = vec[0].first;
  for (int i = 1; i < n; ++i) {
    if (vec[i].second >= taken) {
      ans++;
      taken = vec[i].first;
    }
  }
  cout << ans << endl;
  return 0;
}
