A Thief has finally entered Mr Roy's house while he was busy spending time with his family at Sikkim.
The thief is very much addicted to technology and uses a special bag that comes with device which automatically detects the most costly item among all the items that he uses to scan out (at maximum the machine can scan 5 items and minimum of 3 items at one go due to its size).
But there is a bad defect in the machine that is when ever a group of items are scanned the machine destroys (still they could be scanned again by the machine later but their value becomes 0 ) the adjacent item and the item next to the adjacent item on both the sides of the selected item (that is at maximum 4 items are destroyed by the machine) which is the most costliest that the thief takes with him in that special bag.
But there is a problem ,the thief is very much confused in which order he should scan the items with his machine and more over the order in which the items are placed cannot be modified.But at the same time he is greedy and wants to take the most costly items along with him.
So what can be the maximum value that can be made by the thief if he uses his peculiar machine to steal the items from Mr Roys house.
Since the thief is confused he asks for your help! Can you help him to find the maximum value that can be possibly made?
Input Format:
First line of input is number of test cases T.
Each test case is comprised of two inputs
First input of a test case is the number of items N
Second input is N integers delimited by whitespaces denoting value of each items.
Output Format:
For each test case, output one line containing "Case #x: y", where x is the test case number (starting from 1) and y is the maximum value that can be made and if it is not possible to scan items then print -1.
Constraints:
1 ≤ T ≤100
1 ≤ N ≤ 1000
1 ≤ [value of each item] ≤ 10000000
The Theif covers item 3 to 5 by his machine and selects 5.
Again he covers item 1 to 4 by his machine and selects 2 (item 3 and 4 has value = 0 since they get destroyed previously).
Hence the maximum value that can be obtained is 7.