Abhishek enters the portal of his dream place ISRO and finds the following riddle given on the assignment board.
There is a series of 3 numbers written on a piece of paper on separate lines.
With the proper use of the mathematical operators '+', '*' and the parantheses, your goal is to maximize the number evaluated from the formed expression, without changing the order of the given integers.
Suppose we have on the first line, the numbers, 1,2 and 3, then, we can have several possibilities :
1+(2*3) = 7
1*(2+3) = 5
1*2*3 = 6
(1+2)*3 = 9
Of course, the maximum number obtained for the above numbers 1,2,3 in order would be 9.
We could also be tempted to write expression such as 1*3+2, but that would amount to changing the order, and hence would be treated as an invalid expression.
Since Abhishek is from a CS background and wants to find the answer to these numbers really quick to impress the girls, he asks you to devise a computer program to do the same.
Your task is to print the maximum value from the same.
The first line consists of integer t, denoting the number of test cases. (1≤t≤104)
Each of the next input contains 3 integers, a,b and c, each on separate lines(1≤a,b,c≤10 )
Print the maximum number that can be obtained from the given 3 numbers.
For each test case, print the answer to a new line.