Rectangles and nails
Very easy
Execution time limit is 1 second
Runtime memory usage limit is 64 megabytes
On the coordinate plane given N rectangles - kozhdy pair of opposite vertices, sides are parallel to coordinate axes and coordinates of the vertices - integers from the interval [-50, 50]. What is the maximal number of rectangles can be nailed to the plane of a single nail? Rectangle is considered to be nailed, if a nail hammered into the inner point of the rectangle.
Input
The first line contains one number N. Further, there are N rows of 4 numbers - the coordinates of one of the diagonals of the rectangle.
Output
One number - the largest number of rectangles that can be nailed one nail.
Examples
Input #1
Answer #1
Submissions 957
Acceptance rate 26%