Crime scene#11087

Crime scene

1 second
128 megabytes
Very hard

Crew members located the traitor's crime scene. Now the ship's crew wants to secure this crime scene.

The crime scene looks like a convex polygon A. The crew of the ship wants to enclose it with another convex polygon B. Moreover, B must have the minimum possible number of vertices. And all the vertices of polygon A must lie on the boundary of polygon B.

Help the team to choose such polygon B.

Input

The first line contains one integer (1 \leq t \leq 1000) - the number of test cases. The following is a description of the test cases.

The first line of each test contains one integer (3 \leq n \leq 100) - the number of vertices in polygon A.

The next lines contain two integers x_i and y_i the coordinates of the -th vertex of the polygon (|x_i|, |y_i| \leq 1000). The vertices of the polygon are given in counterclockwise order. It is guaranteed that the polygon is strictly convex. That is, no three of its consecutive vertices lie on the same straight line.

Output

For each test, first print one integer - the number of vertices in the found polygon B.

In the next lines print two real numbers x_i and y_i each, the coordinates of the -th vertex of the polygon. Output polygon vertices in counterclockwise order. The resulting polygon must be strictly convex. Also, all vertices of the source polygon must be at a distance of no more than 10^{-6} from the border of the output polygon.

Examples

Example 1

Loading
Loading