Winning probability to choose a chip of a box. The Player got 10 blue and 10 red chips, and he was offered a game where he should distribute those chips into 2 similar boxes. (All chips should be placed in one of the boxes.) Then, another person randomly chooses a box and then takes out one random chip from this box (unless the box is empty). The player wins if a red chip is drawn and lose otherwise. What's the maximum probability of the player's winning outcome assuming that he distributes chips the right way?
I have been trying this problem for the past 1 week and not able to proceed further.
The best I have reached is:
P(getting R) = P(getting Red | in chosen Box 1)*P(choosing Box 1) + P(getting Red | in chosen Box 2)*P(choosing Box 2)
But not able to think of a method to maximise the probability.
Can anyone please help me with this?
 A: It is more or less clear, that the distribution
$$
\color{red}{1} +
\color{blue}{0} 
\qquad\text{ and }\qquad
\color{red}{9} +
\color{blue}{10} 
$$
in the first box, and respectively in the second box is optimal.
(Or switch boxes.)
The probability of winning is then
$$
\frac 12\cdot 1+\frac 12\cdot \frac 9{19}=\frac{14}{19}\ .
$$
This is the maximal value among all possible ways to split the $20$ chips,
$$
\color{red}{p} +
\color{blue}{q} 
\qquad\text{ and }\qquad
\color{red}{(10-p)} +
\color{blue}{(10-q)} 
$$
where the probability is
$$
\frac 12\cdot \frac {p}{p+q}
+
\frac 12\cdot \frac {10-p}{20-p-q}\ , \qquad p+q\not\in\{0, 20\}\ .
$$

For the sake of completeness, i'll add a...
Proof: Here is a quick estimation.
If $p=0$, we obtain a probability $\le 1/2$, this is not optimal. So
we may and do assume by symmetry that $1\le p\le 5$.
The difference $\displaystyle 
\frac 12\left(\frac {p}{p+q}
+
\frac {10-p}{20-p-q}\right)-\frac {14}{19}
$
has positive denominator, and the numerator is
$$
-5p^2 + 5p + 9pq + 14q^2 - 185 q
\ .
$$
As a function in $q$,
the part $9pq + 14q^2 - 185 q$ is zero in $q=0$, then
it is monotone decreasing on $J:=[0, (185-9p)/2]\supseteq[0, (185-45)/14/2]=[0,5]$, then it increases on an interval of the same length as $J$, "following" $J$, so the value in $10$ is zero or less. This shows that an optimal value is obtained for $q=0$. It remains to maximize $-5p^2+5p$ on $[1,5]$. Of course, $p=1$ gives the maximum.
$\square$
A: Another derivation.
Without loss of generality we may assume that the left box contains $n\le10$ chips with $p$ chips from them being red ($0\le p\le n$).
Then the probability to win
$$
\frac12\left(\frac pn+\frac{10-p}{20-n}\right)=\frac{5n+p\,(10-n)}{n\,(20-n)}
$$
for $n<10$ is obviously maximized by the choice of the largest possible $p$, i.e. $p=n$, so that the expression to maximize is:
$$
\frac{5n+n\,(10-n)}{n\,(20-n)}=\frac{n(15-n)}{n(20-n)},
$$
which is clearly minimized by the choice of the smallest possible $n$ except for $0$, i.e. $n=1$.
That means that one red chip should be placed in one box, and the other 19 chips in the other box.
