5. For an activity group, if five 13-year-old members leave, or if five 17-year-old members join (the two scenarios do not occur simultaneously), the average age of the members increases by 1 year. Then the original number of members in this activity group is ( ).
(A) 10
(B) 12
(C) 14
(D) 16
5. A.

Let the original number of members in the activity group be $x$, and the total sum of their ages be $y$.
From the problem, we have
$$
\begin{array}{l}
\left\{\begin{array} { l } 
{ \frac { y - 65 } { x - 5 } = \frac { y } { x } + 1 , } \\
{ \frac { y + 85 } { x + 5 } = \frac { y } { x } + 1 }
\end{array} \Rightarrow \left\{\begin{array}{l}
x^{2}+60 x=5 y, \\
x^{2}-80 x=-5 y
\end{array}\right.\right. \\
\Rightarrow 2 x^{2}-20 x=0
\end{array}
$$