Binomial probability:
the chance of exactly k successes in n tries
Count the ways, multiply by the chance of each way, and you have an exact probability for any number of repeated yes/no trials.
Calcylator Editorial Team
Updated · 4 min read
When a situation counts as binomial
Some everyday questions are really one problem in different clothes: how likely is it that exactly 5 of 8 free throws go in, that 2 of 3 tosses land heads, that 3 of 20 bulbs in a box are faulty? In each, you repeat a trial a fixed number of times, each trial has two outcomes and the same chance of success, and the trials do not influence each other.
Those four conditions define a binomial experiment: a fixed number of trials n, two outcomes, a constant success probability p, and independence. If any one fails, such as drawing cards without replacement from a small deck, the answer needs a different model.
The word success carries no moral weight in this setting. A defective bulb can be the success if defects are what you are counting, and a failed delivery can be a success in an audit of late shipments. Choose whichever outcome makes the question easiest to state, and keep p tied to that choice from start to finish.
Building the formula from two pieces
- n:
- number of trials
- k:
- number of successes wanted
- p:
- probability of success on one trial
- C(n, k):
- n! ÷ (k! × (n − k)!), the number of ways to arrange the successes
Two ideas combine. First, any single sequence with k successes and n − k failures has probability pᵏ × (1 − p)ⁿ⁻ᵏ, because the trials are independent and probabilities multiply. Second, there are C(n, k) different sequences that contain exactly k successes, and each is a separate way to reach the same count, so their probabilities add.
That is why the coefficient sits in front: it counts the arrangements, while the powers give the weight of each arrangement.
Warm-up: two heads in three tosses
n
3 tosses
k
2 heads
p
0.5
Ways
C(3, 2) = 3
Each way
0.5² × 0.5¹ = 0.125
P(exactly 2 heads)
3 × 0.125 = 0.375 = 37.5%
The three arrangements are HHT, HTH and THH.
Listing the arrangements by hand is possible here, but not for 8 trials, where a count of 56 arrangements is needed. The combination formula does that listing for you.
The coefficient is worth a short calculation by hand. C(8, 5) = 8! ÷ (5! × 3!) = (8 × 7 × 6) ÷ (3 × 2 × 1) = 336 ÷ 6 = 56. Cancelling the common factorials first keeps the numbers small, and it is also why C(n, k) equals C(n, n − k): choosing which 5 shots go in is the same as choosing which 3 miss.
Worked example: exactly 5 of 8 free throws
A player makes 60% of free throws, and the throws are treated as independent. What is the probability of exactly 5 successes in 8 attempts?
n
8
k
5
p
0.6, so 1 − p = 0.4
C(8, 5)
56
0.6⁵
0.07776
0.4³
0.064
P(X = 5)
56 × 0.07776 × 0.064 ≈ 0.2787, or 27.9%
The full distribution helps to place that figure. The most likely single count is 5, but even it happens less than 3 times in 10.
| Successes k | Probability |
|---|---|
| 0–2 | 0.0499 |
| 3 | 0.1239 |
| 4 | 0.2322 |
| 5 | 0.2787 |
| 6 | 0.2090 |
| 7 | 0.0896 |
| 8 | 0.0168 |
The probabilities sum to 1. The expected number of successes is n × p = 8 × 0.6 = 4.8, so the mean is near 5 but the exact value of 4.8 is not itself possible, which is normal for a discrete count.
It is worth glancing at the symmetry of the table too. With p = 0.6, the distribution leans toward the higher counts. With p = 0.5 it would be perfectly symmetric about 4 for 8 trials, and with p below 0.5 it would lean the other way. The shape is a quick visual check that the p you used is the one you meant.
Mean, spread and a quality-control example
- n:
- number of trials
- p:
- success probability
For the free-throw case, the mean is 8 × 0.6 = 4.8 and the standard deviation is about 1.39. The numbers describe where the counts cluster, and they let you judge quickly whether an observed result is ordinary or surprising.
Quality control shows the formula in a different setting. A box contains 20 bulbs, each with an independent 3% chance of being faulty. The chance that exactly one is faulty is 20 × 0.03 × 0.97¹⁹ = 0.336, or 33.6%. The chance of exactly two is C(20, 2) × 0.03² × 0.97¹⁸ = 190 × 0.0009 × 0.5780 = 9.9%.
The chance of finding no faulty bulb at all is 0.97²⁰ = 0.544, so the chance of at least one is 0.456. In other words, with a 3% defect rate, nearly half of all boxes of 20 contain a faulty bulb, which is a good illustration of how small per-item risks accumulate over a batch.
Exactly k versus at least k
The formula gives the chance of one specific count. Questions are often phrased as at least or at most, which require adding several terms. The chance of at least 5 successes in 8 is P(5) + P(6) + P(7) + P(8) = 0.2787 + 0.2090 + 0.0896 + 0.0168 = 0.5941, about 59.4%.
- At most k: add the terms from 0 up to k.
- At least k: add the terms from k up to n, or compute 1 minus the chance of k − 1 or fewer.
- Between a and b inclusive: add the terms from a to b.
Checks and pitfalls
Sanity-check the answer against the expected value. Most of the probability mass sits within a couple of standard deviations of n × p, where the standard deviation is √(n × p × (1 − p)); here that is √1.92 ≈ 1.39, so counts from about 2 to 7 hold nearly everything.
- Using p for a failure by mistake: swap p and 1 − p if you count the wrong outcome.
- Forgetting the combination coefficient and reporting only the probability of one sequence.
- Assuming independence when it does not hold, such as shooting streaks or items sampled without replacement from a small batch.
- Taking p from a small sample as if it were known exactly.
A basic probability tool covers the favourable-over-total case, and an expected-value tool computes n × p. Both are helpful context, but neither evaluates the binomial formula itself, so work through the three pieces above for exact figures.
Common questions
What is the formula for exact binomial probability?
P(X = k) = C(n, k) × pᵏ × (1 − p)ⁿ⁻ᵏ. C(n, k) counts the arrangements, p is the success chance per trial, and 1 − p the failure chance. For n = 3, k = 2, p = 0.5, the result is 3 × 0.125 = 0.375.
How do I calculate the probability of exactly 5 successes in 8 trials?
Find C(8, 5) = 56, then multiply by p⁵ and (1 − p)³. With p = 0.6, that is 56 × 0.07776 × 0.064 = 0.2787, so about 27.9%. Always make sure the trials are independent with a constant p.
What does C(n, k) mean?
C(n, k), read as n choose k, is the number of ways to select k successes from n trials, n! ÷ (k! × (n − k)!). For C(8, 5) it is 56, and for C(3, 2) it is 3. It multiplies the probability of a single arrangement.
How do I find the probability of at least k successes?
Add the exact probabilities for k, k + 1, up to n, or take 1 minus the probability of fewer than k. For at least 5 of 8 at p = 0.6, adding 0.2787, 0.2090, 0.0896 and 0.0168 gives about 0.594.
When is the binomial model not appropriate?
When trials are not independent, when the success probability changes, or when there are more than two outcomes. Drawing without replacement from a small population is a typical case, where the hypergeometric distribution is the right model instead.
Was this guide helpful?
Continue reading
View all blogsPearson Correlation: Calculate r Step by Step
Pearson's r ranges from −1 to +1. For x = 1…5 and y = 2, 1, 4, 3, 5 the sum-of-products method gives r = 0.80. See the steps and an outlier trap.
5 min read
Probability Basics: Favourable Over Total Outcomes
Probability is favourable outcomes divided by total equally likely outcomes: rolling a 5 on a fair die is 1/6, or 16.7%. Plus AND, OR and complement rules.
5 min read
How to Find Quartiles and the IQR
Q1, Q3 and the IQR explained with a 12-value set: Q1 = 12.5, Q3 = 25, IQR = 12.5, and the 1.5 × IQR fences flag 58 as an outlier.
5 min read




