#K70672. Minimum Water Bottles Problem
Minimum Water Bottles Problem
Minimum Water Bottles Problem
Contestants are given the task of determining the minimum number of 2-liter water bottles required to supply water to a group of runners. Each runner requires (Y) liters of water, and there are (M) runners. The minimum number of bottles needed can be computed using the formula: [ \lceil \frac{M \times Y}{2} \rceil ] where (\lceil x \rceil) denotes the ceiling function which rounds (x) up to the nearest integer. Your solution should read input from standard input and output the result to standard output.
inputFormat
The first line of the input contains a single integer (T), denoting the number of test cases. Each of the next (T) lines contains two space-separated integers (M) and (Y), representing the number of runners and the liters of water required per runner, respectively.
outputFormat
For each test case, output one line containing a single integer — the minimum number of 2-liter water bottles required.## sample
3
2 3
5 4
3 2
3
10
3
</p>