In any coin toss the P(H) = P(T) = $\large\frac{1}{2}$

A fair coin is tossed thrice. The sample space of three tosses of a coin is: $\begin{Bmatrix} HHH & HHT & HTH & HTT \\ TTT & TTH & THT & THH\\ \end{Bmatrix}$

If X is the random variable, we can see that X = 0, 1, 2 or 3 depending on the # of heads.

P (X = 0) = P (no heads) = P (TTT) = $\large\frac{1}{8}$

P (X = 1) = P (HTT, TTH and THT) = $\large\frac{3}{8}$

P (X = 2) = P (HHT, HTH and THH) = $\large\frac{3}{8}$

P (X = 3) = P (HHH) = $\large\frac{1}{8}$

Therefore, given this probability distribution we can calculate the mean using the formula Mean of the probability distribution = $\sum (X_i \times P(X_i))$

$\Rightarrow$ Mean $= 0 \times \large\frac{1}{8}$ $+ 1 \times \large\frac{3}{8}$ $+ 2\times\large\frac{3}{8}$ $+ 3 \times\large\frac{1}{8} = \frac{12}{8} = \frac{3}{2}$