There are two solid hoops coloures in black. A hoop is area between two concentric cirlce with radius r and R (r<R). The two hoop lie on a completly white plane.
A colourful transition is a close continuos line through which there should be change of colour. Given co-ordinate of two hoops find the number of circular colourful transitions.
Input:
Input contains two lines: description of each hoop.
Each line contains 4 space seperated integers:
x,y,r,R
where x,y is co-ordinate of center of the hoop. r and R are the radii of the smaller and larger concentric circles of the hoop respectively.
Output:
A single integer: total possible number of circular colourful transition.
Constraints:
-100<=x,y<=100, 1<=r<R<=100
Sample Input
60 60 45 55
80 60 15 25
Sample Output
4