Five friends just finished a race. How many different ways can they fill gold, silver, and bronze?
Now a different question. Same five friends. How many different 3-person teams can you send to the next relay?
Both questions start from the same 5 people. Both pick 3 of them. But the answers are nowhere close, one is six times bigger than the other. The whole gap comes down to one thing: does order matter?
That question is the entire difference between a permutation and a combination. Get comfortable asking it, and you'll never mix the two up again.
Does order matter here?
Think about the medals first. If Amara gets gold, Ben gets silver, and Chike gets bronze, that's a completely different outcome from Ben getting gold, Amara getting silver, Chike bronze. Same three people. Different result. Order changes the outcome.
Now think about the relay team. If the coach picks Amara, Ben, and Chike for the team, it doesn't matter what order she wrote their names down in. It's the same team either way. Order changes nothing.
That's it. That's the whole distinction. When arranging or assigning matters, you're counting permutations. When only the group itself matters, you're counting combinations. Everything else in this post is just working out how to count each one.
Permutations: filling slots one at a time
Let's count the medal ceremony. There are 5 runners and 3 slots: gold, silver, bronze.
For gold, any of the 5 runners could win it. Once gold is taken, only 4 runners are left for silver. Once silver is taken, only 3 are left for bronze.
So the count is .
Each podium slot you fill shrinks the pool by one, click through the levels and watch the branches multiply.
Watch what happens as you fill each slot: the pool shrinks by exactly one every time, and the branches multiply. That shrinking pool is the entire mechanism. A permutation is just a sequence of choices, each one slightly more limited than the last.
We write this as , the number of ways to arrange items chosen from :
And here's a shortcut using factorials. Since , we can write the same product more compactly by dividing out the part we don't want:
For our race, . Same answer, cleaner notation.
Combinations: when order stops mattering
Now for the relay team. We're still picking 3 out of 5 people. But this time, Amara-Ben-Chike and Ben-Amara-Chike aren't two different outcomes, they're the same team.
Here's the thing: for every team of 3, there are multiple ways to have "arrived" at that same team through an ordered selection. How many? Exactly as many as there are ways to arrange 3 people, which is .
Every ordered medal outcome for the same 3 people gets its own tile, flip the switch and watch identical teams collapse into one box.
Flip between the two views. Ungrouped, you see all 60 ordered outcomes sitting there as separate tiles. Grouped, those 60 tiles collapse down into 10 boxes, each one holding exactly 6 tiles that used to look different but are secretly the same team.
That's the whole trick. Combinations are permutations with the reordering divided back out:
For our relay team, . Ten possible teams, versus sixty possible medal ceremonies, from the exact same five people.
Why does the gap get so much bigger?
The gap between and is always a factor of . That sounds small when is 3. It stops sounding small very quickly.
Log scale, so we can fit all three curves, drag n and watch how much faster the permutation curve climbs than the combination curve.
Slide up and watch the permutation curve pull away from the combination curve, even on a scale that's already compressing the numbers logarithmically. By the time , there are over 700 permutations of 3 items but only 120 combinations, and the ratio between them, 6, never changes. What changes is how much both numbers explode as the pool grows, and permutations always explode faster because they're carrying that extra ordering information along with them.
This is why a 4-digit passcode (order matters, permutation-flavored counting with repetition) has 10,000 possibilities, while a lottery draw of 4 numbers (order doesn't matter once the balls are drawn) has far fewer. The ordering is doing real work in the count.
Try your own numbers
You don't have to trust the formulas, you can watch them agree with each other for any and you pick.
Pick any n and k, the ratio between the two results is always exactly k!, no matter what you choose.
No matter what you set and to, dividing the permutation count by the combination count always lands exactly on . That's not a coincidence, it's the definition. Combinations are permutations with the internal reordering removed, every single time.
The question to ask every time
Next time you're not sure which one you need, skip the formulas and ask this instead:
If I swapped two of my chosen items around, would that count as a different outcome?
- Yes, it's a different outcome? You want a permutation. Passwords, race rankings, seating charts, the order you play songs in.
- No, it's the same outcome either way? You want a combination. Committees, lottery number sets, pizza toppings, hands of cards (the hand itself, not the order you were dealt them).
Order isn't some abstract mathematical detail, it's a question about your actual situation. Once you know the answer, the right formula falls right out.
The short version
A permutation counts arrangements: order matters, so every reshuffling is a new outcome. A combination counts selections: order doesn't matter, so every reshuffling of the same group collapses into one outcome. The two formulas are related by exactly one thing, dividing out the ways to reorder whatever you picked:
Five friends can fill a podium 60 different ways, but they can only form 10 different teams. Same five people, same group size, wildly different numbers, because one question, does order matter, changes everything downstream of it.
All visualizations are interactive React components running entirely in your browser, computing every permutation and combination live rather than looking up precomputed answers. No libraries beyond React.