CODEM2 - Problem2
Two boxes contain the same total numbers of balls having some blacks and some whites in each.From each box "n" number of balls are drawn with replacement.Find the number of white balls in box A if composition of box B is given and such that probability that all white balls are drawn from box A is equal to the probability that the drawing from box B is either all whites or all blacks for the given number of drawings.
T:no of testcases
Next T lines contain 3 integers n,x,y.
For each testcase print in new line "impossible" if it is not possible to find no of white balls in box A else print no of white balls.
2 3 4 Output: 5
x=no of white balls in box B , y=no of black balls in box B
P(A, W) is probability that all n balls drawn from box A are white
please add more test cases
I couldn't understand correctly the problem >:V