How it works
The big question is: does order matter? Choosing 3 students for a team is a combination: Ana, Ben and Cal is the same team in any order. Awarding gold, silver and bronze to 3 of them is a permutation: Ana-gold, Ben-silver is different from Ben-gold, Ana-silver.
Permutations are always at least as many as combinations, because each group of r can be arranged in r! different orders. Allowing repetition, like digits in a PIN, increases the count again.
Formula
- nPr = n! ÷ (n - r)!
- nCr = n! ÷ (r! (n - r)!)
- With repetition: ordered = nʳ; unordered = (n + r - 1)! ÷ (r! (n - 1)!)
- n! = n x (n - 1) x ... x 1, and 0! = 1
Solved example
From 10 students, choose a team of 3: 10C3 = 120 teams. Award 1st, 2nd and 3rd place: 10P3 = 10 x 9 x 8 = 720 ways.
A 5-card poker hand from 52 cards: 52C5 = 2,598,960 possible hands. A 3-digit lock using digits 1-4 with repeats: 4³ = 64 codes.
FAQ
Why is a "combination lock" misnamed?
Because order matters for the code, so it is really a permutation lock (with repetition).
What is 0!?
0! is defined as 1. It makes formulas like nCn = 1 work out: there is exactly one way to choose everything.
How does this connect to probability?
Probability = favourable outcomes ÷ total outcomes, and nCr is often how you count both. The chance of one particular poker hand is 1 in 2,598,960.