The binomial distribution, explained with examples
The binomial distribution counts how many successes you get in a fixed number of independent trials. It models everything from coin flips to free throws to defective products.
On this page
When a situation is binomial: BINS
A random variable X counting successes is binomial when all four conditions hold:
- Binary: each trial has two outcomes, success or failure.
- Independent: the result of one trial does not affect another.
- Number: the number of trials n is fixed in advance.
- Same probability: the probability of success p is the same on every trial.
We write X ~ B(n, p). If you keep going until the first success instead of fixing n, the count is geometric, not binomial. If you sample without replacement from a small population, the trials are not independent; but when the sample is less than 10% of the population, the binomial model is still a good approximation.
The probability formula
P(X = k) = C(n, k) pk (1 − p)n − k
Here C(n, k), also written nCk or “n choose k”, is the number of ways to choose which k of the n trials are successes: C(n, k) = n!/(k!(n − k)!). The term pk(1 − p)n − k is the probability of any one particular arrangement of k successes and n − k failures. Multiply them to get the total probability.
Mean and standard deviation
For X ~ B(n, p): mean μ = np and standard deviation σ = √(np(1 − p)). If a basketball player makes 80% of free throws and takes 20, she expects to make 20 × 0.8 = 16, with a standard deviation of √(20 × 0.8 × 0.2) ≈ 1.79. On AP free-response questions, you may need to interpret the mean: “If she took many sets of 20 free throws, she would make about 16 per set on average.”
Worked examples
Example 1: an exact probability
A fair coin is flipped 10 times. Find P(exactly 6 heads).
- X ~ B(10, 0.5). P(X = 6) = C(10, 6)(0.5)6(0.5)4 = 210/1024.
- = 0.205.
Example 2: a multiple-choice quiz
A student guesses on 8 questions, each with 4 options. Find the probability of getting exactly 3 right.
- X ~ B(8, 0.25). P(X = 3) = C(8, 3)(0.25)³(0.75)5 = 56 × 0.015625 × 0.2373.
- ≈ 0.208.
Example 3: at least one
A component fails with probability 0.02. In a batch of 50, find P(at least one fails).
- Use the complement: P(X ≥ 1) = 1 − P(X = 0) = 1 − 0.9850.
- ≈ 1 − 0.364 = 0.636. “At least one” questions are almost always quickest with the complement.
Example 4: a cumulative probability
X ~ B(12, 0.3). Find P(X ≤ 2).
- P(X = 0) = 0.712 ≈ 0.0138; P(X = 1) = 12(0.3)(0.7)11 ≈ 0.0712; P(X = 2) = 66(0.09)(0.7)10 ≈ 0.1678.
- Sum ≈ 0.253. On a calculator, binomcdf(12, 0.3, 2) gives this directly.
Example 5: more than a value
With X ~ B(12, 0.3), find P(X > 2).
- P(X > 2) = 1 − P(X ≤ 2) = 1 − 0.253 = 0.747.
- Be careful with the boundary: > 2 starts at 3, so subtract P(X ≤ 2), not P(X ≤ 3).
Example 6: mean and SD
A survey finds 40% of students walk to school. In a random sample of 50, find the mean and standard deviation of the number who walk.
- μ = 50 × 0.4 = 20; σ = √(50 × 0.4 × 0.6) = √12 ≈ 3.46.
Example 7: is this result unusual?
In the sample of 50, only 10 walked. Is that surprising if p = 0.4?
- 10 is (10 − 20)/3.46 ≈ −2.9 standard deviations below the mean.
- P(X ≤ 10) ≈ 0.0022, so yes, this would be very unusual if 40% truly walk. It gives evidence that the true proportion is lower.
The shape of a binomial distribution
When p = 0.5, the distribution is symmetric. When p is small, it is skewed right, with most of the probability near zero. When p is large, it is skewed left. As n grows, the distribution becomes more bell-shaped. A common rule is that when np ≥ 10 and n(1 − p) ≥ 10, the binomial distribution is approximately normal. This is the large counts condition you use for confidence intervals and tests about proportions.
Binomial versus geometric
Both models involve independent trials with the same probability of success. The difference is what is counted. A binomial variable counts successes in a fixed number of trials, so its values run from 0 to n. A geometric variable counts the number of trials until the first success, so its values start at 1 and have no upper limit. Asking “is the number of trials fixed?” tells you which model to use.
Using a calculator
On a TI-84, binompdf(n, p, k) gives P(X = k) and binomcdf(n, p, k) gives P(X ≤ k). For P(X ≥ k), use 1 − binomcdf(n, p, k − 1). On the AP exam, define the variable and distribution in words, such as “Let X = number of students who walk, X ~ B(50, 0.4)”, then write the probability statement before the answer.
Common mistakes
- Using the binomial model when the number of trials is not fixed (that is geometric).
- Getting inequality boundaries wrong, such as P(X < 3) versus P(X ≤ 3).
- Forgetting the C(n, k) factor in the formula.
- Using σ = np(1 − p) without the square root.
Practice questions
Try each one before opening the answer.
Q1. X ~ B(5, 0.5). Find P(X = 5).
Show answer
Q2. X ~ B(20, 0.1). Find the mean and SD.
Show answer
Q3. X ~ B(6, 0.2). Find P(X ≥ 1).
Show answer
Q4. Is rolling a dice until you get a 6 binomial? Why?
Show answer
Q5. X ~ B(100, 0.3). Is a normal approximation reasonable?
Show answer
Frequently asked questions
Is the binomial distribution on the AP Statistics exam?
Yes. It is in Unit 4, probability, random variables and probability distributions, and it underpins inference for proportions later in the course.
Is the binomial distribution in A level Maths?
Yes. It is in the first year of A level Maths and is used in binomial hypothesis tests. It also appears in some IB and university courses.
What is the difference between binompdf and binomcdf?
binompdf gives the probability of exactly k successes. binomcdf gives the probability of k or fewer.
Key takeaways
- Check BINS before using a binomial model.
- P(X = k) = C(n, k)pk(1 − p)n − k.
- Mean np; standard deviation √(np(1 − p)).
- Use complements for “at least one”.
- When np and n(1 − p) are at least 10, it is approximately normal.