[Math] The frog puzzle

intuitionprobabilitypuzzle

So here's the puzzle. You're poisoned in the jungle and the only way to save yourself is to lick a special kind of frog. To make matters worse, only the female of that species will do. Licking the male frog doesn't do anything.
The male and female frogs look identical. The only difference is that the male frog makes a sound and the female is silent.

So you run through the jungle and spot a frog in front of you. Before you could start running towards it you hear a sound behind you. You turn around and spot two frogs there. There's only time to run to one side.

Now, the best course of action is to run towards the two frogs and lick both. The reasoning is that there are 4 possible combinations of two frogs and knowing that one of them is male eliminates only one of those possibilities. Of the remaining three, two of them have at least one female frog. This gives you a $\frac 2 3$ chance of survival as opposed to a $\frac 1 2$ with the single frog.

Now here's my problem. The reason this works is because you don't know which frog made the sound. If you did, you'd have a $50\%$ chance with the other one. But wouldn't that imply that, if you for some reason turned around earlier to see which one made the sound, you would decrease your chances of survival? What's the explanation here?

Best Answer

In the two-frog scenario, the event "One croak was heard" is not the same as the event "at least one frog is male".

There are eight possibilities: the "left" frog can be female or male, the "right" frog can be female or male, and exactly one croak was emitted or not. Assuming males croak with probability $p$ while you are in their presence, and everything is independent, the following table enumerates the eight possibilities and their probabilities: $$ \begin{array}{c|l|c|c|c|c} \text{Outcome} & \text{Probability} &\text{One croak?}&\text{F present?}&\text{At least one M?}\\ \hline FF0 & \frac14 & & Y&\\ FF1 &0&Y&Y&\\ FM0 &\frac14(1-p) &&Y&Y\\ FM1&\frac14p&Y&Y&Y\\ MF0&\frac14(1-p)&&Y&Y\\ MF1&\frac14p&Y&Y&Y\\ MM0&\frac14(p^2+(1-p)^2)&&&Y\\ MM1&\frac14\cdot 2p(1-p)&Y&&Y\\ \end{array} $$ Using the above table, the probability that you survive given you heard a croak is $$ P(\text{F present}\mid\text{one croak})=\frac{P(FF1,FM1,MF1)}{P(FF1,FM1,MF1,MM1)}=\frac{0+\frac14p+\frac14p}{0+\frac14p+\frac14p+\frac142p(1-p)}=\frac1{2-p}. $$ This makes intuitive sense, because if males croak all the time ($p=1$), then for sure the other frog is female; if males croak but very rarely, then it's a coin toss whether the other frog is female. Note that the above probability is never smaller than $\frac12$, so the two-frog lick is always a better strategy than the one-frog lick.

Using the above table, the probability $P(\text{survive}\mid\text{at least one M})$ is properly calculated as $2/3$, but this result is neither here nor there, because you didn't observe that event.

As for your other question, we can modify the outcome space to specify whether the left frog croaked or the right one. Using a similar enumeration to the above, the prob that you survive given you heard a croak from only the left frog is: $$P(\text{F present}\mid\text{only left frog croaked}) ={P(M1F0)\over P(M1F0,M1M0)}={\frac12p\cdot\frac121\over\frac12p\cdot\frac121+\frac12p\cdot\frac12(1-p)}=\frac1{2-p}, $$ exactly the same probability as when you didn't know which frog croaked. The probability of survival given that only the right frog croaked is the same. Conclusion: knowledge of which frog croaked does not lower your probability of survival.

Related Question