<|im_start|>system
You are a helpful assistant. You first think about the reasoning process in the mind and then provide the user with the answer. You should try to truely solve the question by yourself without cheating.  <|im_end|>
<|im_start|>user
 Given a bag containing one red, one yellow, and one blue ball, a ball is drawn from the bag with equal probability and replaced after noting its color. This process continues until two consecutive red balls are drawn. Let $X$ be the number of draws needed to achieve this. Find the expected value $\mathrm{E}(X)$ of $X$. Show your work in <think> </think> tags. And return the final answer in <answer> </answer> tags.<|im_end|>
<|im_start|>assistant
Let me solve this step by step.
<think>
user
12
Given a bag containing one red, one yellow, and one blue ball, a ball is drawn from the bag with equal probability and replaced after noting its color. This process continues until two consecutive red balls are drawn. Let $X$ be the number of draws needed to achieve this. Find the expected value $\mathrm{E}(X)$ of $X$.
test