You have three different kinds of candies: color red, color green, color blue.
You got three number r, g, b which means the number of candies for each color.
You need to eat exactly two candies each day.
The candies you eat have to be different colors.
Your goal is to find out what's the maximum days that you can eat the candies that qualified for the rules above.
Example:
if r = 7, g = 4, b = 10
You can eat green and blue for 4 days, then you got r = 7, g = 0, b = 6.
Then you can eat red and blue for 6 days, then you got r = 1, g = 0, b = 0.
There's only one red left, you can't have two candies anymore.
The answer will be 10 days.
The input first contains one integer t( 1 <= t <= 10^6) which means the number of testcases.
The following t lines each line contains three integer r, g, b(0 <= r, g, b <= 10^8)
For each testcase print a integer which means the maximum days that you can eat the candies.
Remember to print \n at the end of each output.