Circle Regions

No attempts yetTime limit1sMemory limit256 MB

Problem

There are NN circles on the x-axis. Every center lies on the x-axis, and no two circles cross each other. They may touch.

Write a program that counts how many regions the circles cut the plane into.

A region is a set of points, and any two points in it can be joined by a continuous curve that never meets a circle. The unbounded part outside every circle counts as one region.

Input

The first line contains the number of circles NN (1N3000001 \le N \le 300\,000).

Each of the next NN lines contains one circle as two integers xix_i and rir_i. xix_i is the x coordinate of the center and rir_i is the radius. (109xi109-10^9 \le x_i \le 10^9, 1ri1091 \le r_i \le 10^9)

No circle is given twice.

Output

Print the number of regions the circles make.