First, note that $1+7+5+2+5=20$. The mean cannot be $1$ or $2$.  There are $3$ possible cases:  Case 1: the mean is $5$ . $$ X=5 \cdot 6-20=10 \text {. } $$  Case 2: the mean is $7$. $$ X=7 \cdot 6-20=22 \text {. } $$  Case 3: the mean is $X$. $$ \frac{20+X}{6}=X \Rightarrow X=4 \text {. } $$  Hence, the answer is $10+22+4=$ (D) $36$ . 
A data set consists of $6$ (not distinct) positive integers: $1,7,5,2,5$, and $X$. The average (arithmetic mean) of the 6 numbers equals a value in the data set. What is the sum of all positive values of $X$? (2022 AMC 10A Problems, Question \#8) 
Options:
  $$10$$ 
  $$26$$ 
  $$32$$ 
  $$36$$ 
  $$40$$ 