What is the smallest and largest possible values for the variance? Suppose
$P( X \in \{1,2,3\}) = 1$ and  $E(X) =2.5.$

What is the smallest and largest possible values for the variance?

My understand: So what I understand is variance finds the distance between each element and the mean. So the closer 2 is to E(X) the farther 1 and 3 can be from E(X). But I have no clue how to obtain this..

Let $p=\mathsf P(X\in\{1\}), q=\mathsf P(X\in\{2\})$ 
$\begin{align}2.5 ~=~& \mathsf E(X) \\ =~& p+2q+3(1-p-q)\\ =~& 3-2p-q \\ \therefore~q~=~&0.5-2p\end{align}$
Thus $0\leq p\leq 1, 0\leq 0.5 -2p\leq 1$, and $0\leq 1-p-0.5+2p\leq 1$, meaning
$$\therefore~~0\leq p\leq 0.25$$
Now use that and $\mathsf {Var}(X)= p+4q+9(1-p-q)-(2.5)^2 = 2p+0.25$ to find the minimum and maximum variance.
