First, let's calculate the probability of winning the game.
We win the game if we get three heads or three tails, so the probability is:
[tex]\begin{gathered} P(3\text{ heads})=\frac{1}{2}\cdot\frac{1}{2}\cdot\frac{1}{2}=\frac{1}{8}\\ \\ P(3\text{ tails})=\frac{1}{2}\cdot\frac{1}{2}\cdot\frac{1}{2}=\frac{1}{8}\\ \\ P(win)=\frac{1}{8}+\frac{1}{8}=\frac{2}{8}=\frac{1}{4} \end{gathered}[/tex]
If the probability of winning is 1/4, the probability of losing is 3/4.
If the wager is $1, winning will return $4 plus the original bet, so a net earning of $4.
Losing will return nothing, so the net "earning" is -$1.
Calculating the expected value of one game, we have:
[tex]\begin{gathered} E(x)=\sum x\cdot p(x)\\ \\ E(x)=\frac{1}{4}\cdot4+\frac{3}{4}\cdot(-1)\\ \\ E(x)=\frac{4}{4}-\frac{3}{4}\\ \\ E(x)=\frac{1}{4} \end{gathered}[/tex]
Playing 20 times will result in an earning of 20 * 1/4, that is, a gain of $5.
Correct option: fourth one.