CF2061B.Kevin and Geometry

传统题 时间 2000 ms 内存 256 MiB 5 尝试 1 已通过 1 标签

Kevin and Geometry

Kevin has nn sticks with length a1,a2,,ana_1,a_2,\ldots,a_n.

Kevin wants to select 44 sticks from these to form an isosceles trapezoid^{\text{∗}} with a positive area. Note that rectangles and squares are also considered isosceles trapezoids. Help Kevin find a solution. If no solution exists, output 1-1.

^{\text{∗}}An isosceles trapezoid is a convex quadrilateral with a line of symmetry bisecting one pair of opposite sides. In any isosceles trapezoid, two opposite sides (the bases) are parallel, and the two other sides (the legs) are of equal length.

Input

Each test contains multiple test cases. The first line contains the number of test cases tt (1t1041 \le t \le 10^4). The description of the test cases follows.

The first line of each test case contains a single integer nn (4n21054 \le n \le 2\cdot 10^5).

The second line contains nn integers a1,a2,,ana_1, a_2, \ldots, a_n (1ai1081 \le a_i \le 10^8).

It is guaranteed that the sum of nn over all test cases does not exceed 21052\cdot 10^5.

Output

For each test case, output 44 integers — the lengths of sticks. If no solution exists, output 1-1.

If there are multiple solutions, print any of them.

Note

In the first test case, you can form an isosceles trapezoid with bases of length 55 and 1010, and two legs of length 55.

In the second test case, you can form an isosceles trapezoid with two bases of length 55 and two legs of length 1010. A rectangle is considered an isosceles trapezoid here.

In the third test case, there are no sticks with the same length. It's impossible to form an isosceles trapezoid.

In the fourth test case, it's impossible to form an isosceles trapezoid with a positive area.

Samples

7
4
5 5 5 10
4
10 5 10 5
4
1 2 3 4
4
1 1 1 3
6
4 2 1 5 7 1
6
10 200 30 300 30 100
4
100000000 100000000 1 2
5 5 5 10
5 5 10 10
-1
-1
1 1 4 5
-1
100000000 100000000 1 2

在线编程 IDE

建议全屏模式获得最佳体验