Colored Rectangles
When Vitek learned about the Pythagorean theorem in geometry class, he momentarily put aside his dreams of becoming a politician and decided to pursue a career in mathematics. He realized that true eternal values are found in science, and the names of great mathematicians are remembered forever. On the very first day of this pivotal decision, he began preparing for future discoveries.
Using graph paper, Vitek drew a coordinate system and started sketching rectangles in the first quadrant. None of these rectangles overlapped or touched each other. After constructing N rectangles, he began to color them. Rectangles fully visible from the origin were colored green, those partially visible were colored red, and those not visible at all from the origin were colored blue.
What intrigued him most was determining the number of rectangles he colored blue.
Input
The first line contains the number of rectangles, N (1 ≤ N ≤ 1000). The following N lines each contain 4 integers separated by spaces, representing the coordinates of the lower left and upper right corners of each rectangle.
0 < X_1, Y_1, X_2, Y_2 ≤ 30000
Output
Output a single number: the count of blue rectangles.