
	 Starting with an empty string, we create a string by repeatedly appending one of the letters $H$, $M$, $T$ with probabilities $\frac 14$, $\frac 12$, $\frac 14$, respectively, until the letter $M$ appears twice consecutively. What is the expected value of the length of the resulting string?

Let's think step by step and output the final answer within \boxed{}.
user