题目描述
Chef has an array of N natural numbers. Cheffina challenges the chef to choose the two numbers from the array and following the condition as the area of the rectangle formed from the two numbers is maximum. Cheffina also asks the chef to choose two numbers different from the previous two to form the rectangle with a minimum area.
-----Input:-----
- First-line will contain $T$, the number of test cases. Then the test cases follow.
- Each test case contains a single line of input, $N$.
- N space-separated natural numbers.
-----Output:-----
For each test case, output in one line answers maximum and minimum area of a rectangle.
-----Constraints-----
- $1 \leq T \leq 10$
- $4 \leq N \leq 10^5$
- $1 \leq arr[i] \leq 10^6$
-----Sample Input:-----
1
5
4 2 1 5 3
-----Sample Output:-----
20 2
输入格式
见题面
输出格式
见题面