6. Given that $m$ and $n$ are positive integers, satisfying $m+10<n+1$, for the set
$$
\{m, m+4, m+10, n+1, n+2, 2n\},
$$

the average and median are both $n$. Then the value of $m+n$ is ( ).
(A) 20
(B) 21
(C) 22
(D) 23
(E) 24
6. B.

From the problem, we know
$$
\begin{array}{l}
\frac{m+m+4+m+10+n+1+n+2+2 n}{6} \\
=\frac{m+10+n+1}{2}=n \\
\Rightarrow(m, n)=(5,16) \Rightarrow m+n=21 .
\end{array}
$$