Problems
Quadrilateral
Quadrilateral
The arbitrary quadrilateral is given on a plane with coordinates of its successive vertices. Find the number of right angles in quadrilateral.
Input
Consists of coordinates of successive vertices in quadrelateral with integer values not greater than 100 by absolute value.
Output
Print the number of right angles in quadrilateral.
Input example #1
-1 0 -1 4 2 4 4 1
Output example #1
1