Imagine we have six nodes, labeled 0 through 5. One can transition from node $i$ to $i+1$ with probability $p$ or can remain at node $i$ with probability $1-p$. Note that once one transitions to a node, it cannot backtrack. See the following figure for an illustration.
I want to know the expected time it takes to reach node 5 assuming you start at node 0. I started to write down the following outcomes below:
- 5 transitions, 0 stops (5 time-steps)
- 5 transitions, 1 stop (6 time-steps)
- 5 transitions, 2 stops (7 time-steps)
- and so on...
where "stop" means no transition was made. Once we list all of the cases then it's just a matter of computing the probabilities. Problem is, I don't know how to write out all of the cases (infinitely many?). Is this the right way of thinking about it?