= Solution
For $1\leq i\leq k$, the success <probability> is $i/k>0$, and the definition of <conditional expectation> on an <event> gives
$$
\mathbb E_i[X\mid J=1]
=\frac{\mathbb E_i[X\mathbf1_{\{J=1\}}]}{\mathbb P_i(J=1)}
=\frac{i(k^2-i^2)/(3k)}{i/k}.
$$
Therefore
$$
\boxed{\mathbb E_i[X\mid\text{reach }k]=\frac{k^2-i^2}{3}\text{ minutes}.}
$$
At $i=k$ the value is zero because the trial has already ended. At the left absorbing state $i=0$, conditioning on success would be undefined because it has zero <probability>. The formula concerns the successful trajectories, so it need not equal the unconditional mean $i(k-i)$.
Back to article page