Maximize Red Marble Probability with Two Drawers

Probability · Medium · Free problem

You have 100 marbles -- 50 red and 50 blue. You must distribute all 100 marbles between two drawers, subject to two constraints: no marbles left outside, and each drawer must contain at least one marble.

Once the marbles are placed, you pick one of the two drawers uniformly at random, then draw one marble uniformly at random from that drawer.

How should you distribute the marbles to maximize the probability of drawing a red marble? What is that maximum probability?

Hints

  1. Each drawer is chosen with equal probability $1/2$, regardless of how many marbles it contains. How can you exploit a very small drawer?
  2. If one drawer contains only red marbles, it contributes a full $1/2$ to your probability. How few red marbles can you put there while keeping it all-red?
  3. Try putting exactly 1 red marble in one drawer and all other 99 marbles in the second drawer. Compute the total probability and verify that moving more red marbles to the first drawer makes things worse.

Worked Solution

How to Think About It: You are choosing how to split 50 red and 50 blue marbles across two drawers to maximize the probability of drawing red. The key observation is that each drawer gets equal weight (probability $1/2$) regardless of how many marbles it holds. That means a drawer with 1 marble counts just as much as a drawer with 99. This immediately suggests an extreme allocation: if you can make one drawer a sure thing for red, you lock in a full $1/2$ from that drawer, and then you just need to maximize the red fraction in the other drawer.

Quick Estimate: Put 1 red marble in drawer 1, everything else in drawer 2. Drawer 1 gives red with probability 1. Drawer 2 has 49 red out of 99, so roughly $49/99 \approx 0.495$. Total: $(1/2)(1) + (1/2)(0.495) \approx 0.748$. That is way above the naive $0.50$ from any balanced split. Can we do better? If we put 2 red marbles in drawer 1, it is still a guaranteed red draw, but drawer 2 now has $48/98 \approx 0.490$, giving total $\approx 0.745$ -- slightly worse. So the minimum sacrifice (1 marble) is best.

Approach: Write the probability as a function of the allocation and show that the $(1, 0)$-$(49, 50)$ split is optimal.

Formal Solution:

Let drawer 1 contain $r$ red and $b$ blue marbles, with $r + b \geq 1$. Drawer 2 then contains $50 - r$ red and $50 - b$ blue, with $(50 - r) + (50 - b) \geq 1$, i.e., $r + b \leq 99$.

The probability of drawing red is:

$$P(\text{red}) = \frac{1}{2} \cdot \frac{r}{r + b} + \frac{1}{2} \cdot \frac{50 - r}{100 - r - b}$$

To maximize this, note the two terms are independent decisions:

  • First term $\frac{r}{r+b}$: This is the red fraction in drawer 1. It is maximized at 1 when $b = 0$ (drawer 1 has only red marbles). Among all-red choices, taking $r = 1$ minimizes the damage to drawer 2.
  • Second term $\frac{50 - r}{100 - r - b}$: Given $b = 0$ and $r = 1$, this becomes $49/99$. Any larger $r$ (with $b = 0$) gives $\frac{50 - r}{100 - r}$, which is decreasing in $r$ for $r \geq 1$ since the numerator drops by 1 for each unit increase while the denominator also drops by 1 from a larger base (formally, $\frac{d}{dr}\frac{50-r}{100-r} = \frac{-50}{(100-r)^2} < 0$).

Alternatively, could we do better by putting some blue marbles in drawer 1 as well? If drawer 1 has $r$ red and $b > 0$ blue, the first term drops below 1, and we lose more than we could gain back in the second term. For instance, $(25, 0)$-$(25, 50)$: $P = (1/2)(1) + (1/2)(25/75) = 0.5 + 0.167 = 0.667$, much worse.

So the optimal allocation is:

  • Drawer 1: 1 red marble, 0 blue marbles
  • Drawer 2: 49 red marbles, 50 blue marbles

$$P(\text{red}) = \frac{1}{2} \cdot 1 + \frac{1}{2} \cdot \frac{49}{99} = \frac{1}{2} + \frac{49}{198} = \frac{99 + 49}{198} = \frac{148}{198} = \frac{74}{99}$$

Answer: Place 1 red marble alone in one drawer and all remaining 99 marbles (49 red, 50 blue) in the other. The maximum probability of drawing red is $\frac{74}{99} \approx 0.7475$.

Intuition

The key insight is that the two-stage random process (pick a drawer, then pick a marble) gives equal weight to each drawer regardless of size. This decouples the "influence" of a drawer from how many marbles it holds. A drawer with a single marble has just as much sway over the outcome as a drawer with 99 marbles. Once you see this, the strategy is clear: create one drawer that is a guaranteed win (100% red) at the minimum possible cost (just 1 red marble), then let the other drawer be as red-heavy as possible with the remaining stock.

This type of problem appears frequently in quant interviews because it tests whether you can identify and exploit structural asymmetries. The same principle shows up in portfolio construction, market making, and mechanism design: when you have a resource allocation problem where the "weight" of each bucket is fixed (here, each drawer gets probability $1/2$), you should concentrate your best assets in the smallest bucket and spread the rest. It is a discrete version of the idea behind convexity -- splitting resources unevenly beats splitting them evenly whenever the objective is concave in the fraction.

Open the full interactive solver →