This is a binomial distribution scenario. The number of trials is \(n=3\) (the number of coin tosses). The probability of success (getting a head) in a single trial is \(p = \frac{1}{2}\), and the probability of failure (getting a tail) is \(q = 1-p = \frac{1}{2}\). We want to find the probability of getting exactly \(k=2\) heads.
The binomial probability formula is \(P(X=k) = \binom{n}{k} p^k q^{n-k}\).
Substituting the values:
\(P(X=2) = \binom{3}{2} (\frac{1}{2})^2 (\frac{1}{2})^{3-2}\)
\(P(X=2) = \binom{3}{2} (\frac{1}{2})^2 (\frac{1}{2})^1\)
First, calculate the binomial coefficient \(\binom{3}{2}\). This represents the number of ways to choose 2 heads from 3 tosses:
\(\binom{3}{2} = \frac{3!}{2!(3-2)!} = \frac{3!}{2!1!} = \frac{3 \times 2 \times 1}{(2 \times 1) \times 1} = 3\).
Now, substitute this back into the probability formula:
\(P(X=2) = 3 \times (\frac{1}{4}) \times (\frac{1}{2})\)
\(P(X=2) = 3 \times \frac{1}{8}\)
\(P(X=2) = \frac{3}{8}\).
Alternatively, we can list all possible outcomes for 3 coin tosses (H for heads, T for tails):
HHH, HHT, HTH, THH, HTT, THT, TTH, TTT.
There are \(2^3 = 8\) total possible outcomes.
The outcomes with exactly 2 heads are:
HHT, HTH, THH.
There are 3 such outcomes.
Therefore, the probability of getting exactly 2 heads is \(\frac{\text{Number of favorable outcomes}}{\text{Total number of outcomes}} = \frac{3}{8}\).