18 (15 points) Two people, A and B, are playing a certain game. The rules state that the winner of each round gets 1 point, and the loser gets 0 points; the game ends when one person's score is 2 points higher than the other's, and that person wins the game. It is also stipulated that the maximum number of rounds is 20; after 20 rounds, the person with the higher score wins the game, and if the scores are equal, it is a draw. It is known that the probability of A winning each round is $p(0<p<1)$, and the probability of B winning is $q=1-p$. Assuming the results of each round are independent, the game ends after $\xi$ rounds. Find the range of the expected value $E \xi$ of $\xi$.

---

The translation preserves the original text's formatting and line breaks.
18 Let $p(\xi=k)$ denote the probability that the match ends after $k$ games. If $k$ is odd, the difference in scores between A and B is also odd, hence $p(\xi=k)=0$.
Considering the results of the first two games:
(1) A wins both or B wins both, referred to as a decisive pair, with a probability of $p^{2}+q^{2}$;
(2) A and B each win one, referred to as an indecisive pair, with two possible outcomes, hence a probability of $2 p q$.

The match ends after $k$ games, where $k$ must be even. Thus, the 1st and 2nd, 3rd and 4th, ..., $(k-3)$th and $(k-2)$th pairs are all indecisive.
If $k \neq 20$, then the $(k-1)$th and $k$th pair is a decisive pair, thus
$$
p(\xi=k)=(2 p q)^{\frac{k}{2}-1}\left(p^{2}+q^{2}\right) .
$$

If $k=20$, the match must end, so $p(\xi=20)=(2 p q)^{9}$.
In summary,
$$
E \xi=\left(p^{2}+q^{2}\right) \sum_{i=1}^{9} 2 i(2 p q)^{i-1}+20(2 p q)^{9} .
$$

Given $p+q=1$, we know $p^{2}+q^{2}=1-2 p q$. Let $u=2 p q$, then $p^{2}+q^{2}=$ $1-u$, so
$$
\begin{array}{c}
E \xi=(1-u) \sum_{i=1}^{9} 2 i u^{i-1}+20 u^{9} . \\
\text { Let } s=\sum_{i=1}^{9} 2 i u^{i-1}, \text { then } \\
u s=\sum_{i=1}^{9} 2 i u^{i}=\sum_{i=2}^{10} 2(i-1) u^{i-1}=\sum_{i=1}^{10} 2(i-1) u^{i-1}, \\
(1-u) s=\sum_{i=1}^{9} 2 u^{i-1}-18 u^{9}=\frac{2\left(1-u^{9}\right)}{1-u}-18 u^{9}, \\
E \xi=(1-u) s+20 u^{9} \\
=\frac{2}{1-u}\left[1-u^{9}-9 u^{9}(1-u)+10 u^{9}(1-u)\right] \\
=\frac{2\left(1-u^{10}\right)}{1-u} .
\end{array}
$$

Since $0<u \leqslant \frac{1}{2}$, we have $2<E \xi \leqslant 4-\left(\frac{1}{2}\right)^{8}$.