Problems
10043 - Clean Tubs
SUBMIT PROBLEM

Clean Tubs

Time Limit: 1 sec

 

The Problem

Bristy loves flower so much. So she has kept some flower tubs beside the reading table so that she can be chilled if she gets bored in times of reading.

 

But unfortunately she has seen that there’s  some insects in the tubs that were eating flowers and also making her table dirty . The total number of tubs are 4 but she has a spray by which only one tub can be sprayed means insects of that tub will be killed and  its consecutive(left and right) tubs insects also will be killed. As the tubs are  heavy she cant change their position.  Now she has numbered the all the tubs as to the number of insects .Tub containing high number of insects is leveled first. Now she wants to clean the maximum number of tubs and the total number of insects to be killed should also be maximum.

 

Now you will have been told the numbering of 4 tubs. U have to find out the sum of numbering of maximum tubs that  can be cleaned.

 

The Input

In the first line there will be a positive integer T (T<=100) that is the test case. In the next T lines there will be 4 positive integer(1<=N<10000) in each line, numbering of the tubs.

 

The Output

For each test case you have to print the required  answer described above with the case number like that “Case 1: output”. Case have to be printed without quotation.

 

Sample Input

2

1 1 3 1

10 2 8 5

 

Sample Output

Case 1: 5

Case 2: 20

 

 

 

Online Practice Contest 1 [School & College Level]

Problem Setter: Sumaia Bristy (Mentor of NHSPC)