There are n points given in the coordinate plane. First, sort these points by the x coordinate. If the x coordinates are equal, sort by the y coordinate.
The first line contains a natural number n that does not exceed 1000.
The next n lines contain the coordinates of the points, x and y. Their values do not exceed 1000.
The points sorted in n lines.
5 4 1 1 6 2 3 1 4 2 4
1 4 1 6 2 3 2 4 4 1
Login to be able to submit.