Solution (source code)

= Solution

At gross rate $R=5/4$, the conditional up probabilities of the <equivalent martingale measure> are
$$
\boxed{q_0=\frac{(5/4)15-12}{30-12}=\frac38,\quad
q_u=\frac{(5/4)30-36}{45-36}=\frac16,\quad
q_d=\frac{(5/4)12-10}{16-10}=\frac56.}
$$
All lie strictly between zero and one. The four terminal path probabilities are $1/16,5/16,25/48,5/48$ in the order good-good, good-bad, bad-good, bad-bad.