Rice bowl LOVE ! ( Easy)

0

0 votes
Easy
Problem

Goku loves to eat rice bowl . There are N chairs and K rice bowls.You have to arrange the rice bowls on the chairs (one rice bowl at one chair) so that no two rice bowl are adjacent to each other.While doing the arrangement first you have to fill the corner chairs with rice bowl. Now Goku will come and sit on a empty chair where there is a ricebowl kept on at least one of the neighbouring chair.
What you have to do is arrange the rice bowls on the chairs in such a way that the number of seat where goku can sit will be minimum. Do the same thing again but this time you have to maximize the seat where Goku can sit.

Standard Input:
First line contain number of test cases T
Next T lines contains N and K,where N is total number of chairs and K is total number of rice bowls


Standard Output:
For each test case print two integers: minimum and maximum number of chairs where Goku can sit.

If it is not possible to arrange rice bowls in such a way that no two rice bowls are together then print "impossible"

Constraints:
1<=t<=100
1<=n,k<=10^18

Time Limit: 1
Memory Limit: 256
Source Limit:
Explanation

case 1: Since there are 4 chairs available and according to the rules we can't keep two rice bowl adjacent so the output is impossible. case 2 :Two rice bowls are kept at the corners so there are only two adjacent chairs where goku will love to sit.

Editor Image

?