"use strict";function main(arg){arg=arg.trim().split("\n");arg.shift();const data=arg.map(e=>{const row = e.split(" ").map(Number);return [row[0]-row[1],row[1]+row[0]];}).sort((a,b)=>{return a[0] - b[0];});let sum=0;let P=Number.MIN_SAFE_INTEGER;for(let i=0;i<data.length;i++){if(P<=data[i][0]){sum++;P=data[i][1];}}console.log(sum);}main(require('fs').readFileSync('/dev/stdin', 'utf8'));