Combination Calculator
Find the number of ways to choose r items from n items where order does not matter. Shows full formula expansion and lists all combinations for small inputs.
🔢 What is a Combination?
A combination C(n, r) is the number of ways to select r items from a set of n items when the order of selection does not matter. If you are choosing a committee of 3 people from a group of 10, the group {Alice, Bob, Carol} is the same as {Carol, Alice, Bob}: both are one combination. The formula is C(n, r) = n! / (r! × (n-r)!), where n! means n factorial (the product of all positive integers from 1 to n).
Combinations appear in many real-world contexts. In poker, every 5-card hand is a combination: C(52, 5) = 2,598,960 distinct hands from a 52-card deck. In a lottery where you pick 6 numbers from 1 to 49, there are C(49, 6) = 13,983,816 possible tickets. In a biology experiment selecting 4 samples from a batch of 20, C(20, 4) = 4,845 ways to draw the sample. Any time you are grouping or selecting without regard to sequence, you are working with combinations.
The key distinction from permutations: combinations ignore order, permutations do not. Selecting 3 toppings for a pizza does not depend on which order you point at them (combination). Assigning gold, silver, and bronze medals to 3 runners from 10 depends on which person gets which medal (permutation). The relationship is P(n,r) = r! × C(n,r): permutations are always larger than or equal to combinations because each unordered group of r items can be arranged in r! different orders.
This calculator computes C(n, r) using the multiplicative formula, which avoids computing full factorials and stays numerically stable for large inputs. For small inputs (n ≤ 10, r ≤ 5), the List All mode generates every actual combination as a set, which is useful for students learning combinatorics visually. The expansion shown in the results breaks down the arithmetic step by step so you can follow the calculation manually.
📐 Formula
📖 How to Use This Calculator
Steps
💡 Example Calculations
Example 1 - Choosing a Committee of 3 from 10 People
How many 3-person committees can be formed from a group of 10?
Example 2 - 5-Card Poker Hands from 52 Cards
How many distinct 5-card poker hands are possible from a standard deck?
Example 3 - Lottery: 6 Numbers from 1 to 49
How many possible lottery tickets exist when choosing 6 numbers from 1 to 49?
Example 4 - List All Combinations: Choose 2 from 5
List every way to choose 2 items from a set of 5: {1, 2, 3, 4, 5}
❓ Frequently Asked Questions
🔗 Related Calculators
What is a combination in math and how is it calculated?
A combination C(n,r) counts the number of ways to select r items from a set of n items when order does not matter. The formula is C(n,r) = n! / (r! x (n-r)!). For example, C(5,2) = 5! / (2! x 3!) = 120 / 12 = 10. This means there are 10 ways to choose 2 items from a set of 5.
What is the difference between combinations and permutations?
Combinations count selections where order does not matter (C(n,r) = n! / (r! x (n-r)!)). Permutations count arrangements where order does matter (P(n,r) = n! / (n-r)!). Example: choosing 2 people for a committee from 5 gives C(5,2) = 10 combinations. Arranging 2 people in ranked positions from 5 gives P(5,2) = 20 permutations. Every combination corresponds to r! permutations, so P(n,r) = r! x C(n,r).
How many combinations are there in a deck of 52 cards for 5 cards?
C(52,5) = 2,598,960. This is the total number of distinct 5-card poker hands from a standard 52-card deck. The formula: C(52,5) = (52 x 51 x 50 x 49 x 48) / (5 x 4 x 3 x 2 x 1) = 311,875,200 / 120 = 2,598,960. Of these, 4 are royal flushes, 36 are straight flushes, 624 are four-of-a-kind, and so on.
What is nCr and how do I read the notation?
nCr is shorthand for 'n choose r', which is the combination formula C(n,r). The n represents the total number of items in the set, and r represents the number you are choosing. You read '10C3' as '10 choose 3', which equals 120. Alternative notations include C(10,3), (10 3) (binomial coefficient notation), and 10C3 on calculators.
What is C(n,0) and C(n,n)?
Both equal 1. C(n,0) = 1 because there is exactly one way to choose nothing from a set: the empty set. C(n,n) = 1 because there is exactly one way to choose all n items: take everything. These are the boundary cases of the combination formula and are important base cases in combinatorial proofs and Pascal's Triangle.
Why is C(n,r) equal to C(n, n-r)?
Choosing r items to include in a group is equivalent to choosing n-r items to exclude. Each selection of r items corresponds to exactly one selection of the remaining n-r items. Therefore C(10,3) = C(10,7) = 120. This symmetry property is used to speed up computation: always compute the smaller of C(n,r) and C(n,n-r).
How do I calculate C(49,6) for lottery odds?
C(49,6) = (49 x 48 x 47 x 46 x 45 x 44) / (6 x 5 x 4 x 3 x 2 x 1) = 10,068,347,520 / 720 = 13,983,816. This means there are 13,983,816 possible ways to pick 6 numbers from 1 to 49. Each lottery ticket covers exactly one of these combinations, giving a 1 in 13,983,816 chance of winning the jackpot with a single ticket.
What does it mean when r is greater than n in a combination?
When r > n, C(n,r) = 0. There are zero ways to choose more items than exist in the set. For example, you cannot choose 6 people for a committee from a group of only 4 people. The formula confirms this: n! / (r! x (n-r)!) with r > n would require (n-r)! = (-k)! for a negative integer, which is undefined. By convention C(n,r) = 0 whenever r > n.