Number of expected state transitions for two heads in a row? We know the expected number of coin flips to get two heads in a row is 6.
We have the following states: A: the start: the previous flip was a tail.
B: the previous flip was the first head
C: the end. two heads have been flipped.
The possible transitions are

*

*A-A

*A-B

*B-A

*B-C

What are the expected number of occurrences for each? Obviously, B-C must be 1 because once the state C occurs we stop. It is also obvious #3 can't be more than #2. But I do not quite know how to continue here.
A: If $X_A,X_B$ are the number of times in those states, then $X_B$ is the number of transitions $A\to B.$ $X_B-1$ is the number of transitions from $B\to A,$ and $X_A-X_B$ is the number of transitions $A\to A.$ (Because the first $A$ did not come from a transition, and $X_B-1$ transitions to $A$ came from $B.$)
Now, the expected value for $X_B$ we get: $E(X_B)=1+\frac12E(X_B),$ so $E(X_B)=2.$ But $E(X_A+X_B+1)=7,$ so $E(X_A)=4.$
Then we have $$E({A\to B})=2, \\E(B\to A)=1, \\E(A\to A)=2,\\ E(B\to C)=1.$$

Alternatively, could also start with the recurrences:
$$\begin{align} E(A\to B)&=\frac12(1+E(B\to A)+E(A\to A))\\E(A\to A)&= \frac12(1+E(B\to A)+E(A\to A))\\E(B\to A)&=\frac12 E(A\to B).\end{align}$$
