Combinations vs Permutations: What's the Difference and How to Calculate Both
April 20, 2026 Ā· Math
You're picking 3 ice cream flavors out of 10 options. Does the order matter? If you're listing your top three in preference order ā vanilla first, chocolate second, strawberry third ā then yes, vanilla-chocolate-strawberry is different from chocolate-vanilla-strawberry. But if you're just grabbing three scoops in a bowl, the order doesn't matter at all. Same three flavors, same bowl.
That distinction ā whether order matters or not ā is the entire difference between permutations and combinations. It sounds trivial, but it leads to dramatically different numbers, and knowing which one to use matters a lot more than you'd think. Lottery tickets, passwords, seating arrangements, poker hands ā they all come down to this one question.
Permutations: order matters
A permutation is an arrangement where the order of selection is significant. ABC is a different permutation from BAC, even though they contain the same three letters.
The formula for permutations (without replacement) is:
n = total number of items
r = number of items being selected
! = factorial (n! = n Ć (nā1) Ć (nā2) Ć ... Ć 1)
Let's say you have 10 books and want to arrange 4 of them on a shelf. How many different arrangements are possible?
= 10! Ć· 6!
= (10 Ć 9 Ć 8 Ć 7 Ć 6!) Ć· 6!
= 10 Ć 9 Ć 8 Ć 7
= 5,040 arrangements
Notice how the 6! terms cancel out. That's a useful shortcut ā you don't actually need to compute the full factorial. For nPr, you just multiply the top n numbers starting from n and going down for r terms.
Another example: how many ways can 5 people sit in a row of 5 chairs? That's 5P5:
(0! equals 1 by definition, which always confuses people at first, but it makes the math work consistently.)
Combinations: order does not matter
A combination is a selection where the order is irrelevant. If you pick Alice, Bob, and Carol for a committee, it doesn't matter whether you write it as "Alice, Bob, Carol" or "Carol, Alice, Bob" ā it's the same committee.
The formula for combinations:
This is the same as the permutation formula, but with an extra r! in the denominator. That extra r! divides out all the duplicate arrangements that would otherwise be counted as separate permutations. Since there are r! ways to arrange r items, dividing by r! collapses all the orderings into a single combination.
Example: choosing 3 people from a group of 8 to form a committee:
= (8 Ć 7 Ć 6 Ć 5!) Ć· (3! Ć 5!)
= (8 Ć 7 Ć 6) Ć· (3 Ć 2 Ć 1)
= 336 Ć· 6
= 56 possible committees
Compare this to 8P3, which would be 8 Ć 7 Ć 6 = 336. The permutation count is exactly 6 times larger (that's 3!) because each combination of 3 people can be arranged in 3! = 6 different orders. Same selection, 6 times as many orderings.
Real-world examples
The difference between permutations and combinations shows up constantly in everyday life, often in ways you might not expect.
Lottery numbers
A standard 6/49 lottery draws 6 numbers from a pool of 49. Order does not matter ā drawing 3-12-17-24-31-45 is the same as 45-31-24-17-12-3. So we use combinations:
That's why the odds of winning the jackpot are roughly 1 in 14 million. If order mattered (permutations), there would be 49P6 = 10,068,347,520 possibilities ā over 700 times more. Your odds would be astronomically worse.
Passwords and PINs
A 4-digit PIN uses the digits 0-9, and you can repeat digits (that's called "with replacement"). Order matters here ā 1234 is not the same as 4321. This is a permutation with repetition:
For a password using 8 characters from a 94-character set (upper, lower, digits, symbols):
That's roughly 6 quadrillion. At 1 billion guesses per second, it would take over 192 years to try every combination. This is why length matters so much more than complexity ā adding even one more character multiplies the total by 94.
Poker hands
A standard 52-card deck, draw 5 cards. Order does not matter ā the hand is the same regardless of how the cards are dealt. This is 52C5:
From there, you can work out the odds of specific hands. A royal flush is exactly 4 possible hands (one per suit), so the odds are 4/2,598,960 or about 1 in 649,740. A four of a kind has 624 possible hands, making it 624/2,598,960 or about 1 in 4,165.
Seating arrangements
Arranging 6 people around a circular table: order matters, but rotations of the same arrangement are equivalent (if everyone shifts one seat to the left, it's the same arrangement). The formula for circular permutations is (n-1)!: (6-1)! = 5! = 120 arrangements.
With or without replacement
So far, all the examples assumed you can't pick the same item twice (without replacement). Dealing cards, choosing committee members, arranging books ā once something is picked, it's gone. But some scenarios allow repetition.
A password is the clearest example of "with replacement" ā you can use the letter "A" multiple times in the same password. A lottery is "without replacement" ā once ball #17 is drawn, it can't be drawn again.
The formulas change for "with replacement":
- Permutations with replacement: nr (n choices for each of r positions)
- Combinations with replacement: (n+r-1)Cr (also called "multichoose")
Example: how many 3-scoop ice cream cones can you make from 5 flavors, if you can repeat flavors?
Without replacement (no repeated flavors), it would be 5C3 = 10 cones. Allowing doubles and triples more than triples the possibilities.
Factorial growth is absurdly fast
One thing that surprises people is how quickly factorials grow. This matters because it puts a hard ceiling on what you can brute-force with a computer.
- 5! = 120
- 10! = 3,628,800 (3.6 million)
- 15! = 1,307,674,368,000 (1.3 trillion)
- 20! = 2,432,902,008,176,640,000 (2.4 quintillion)
- 52! = 80,658,175,170,943,878,571,660,636,856,403,766,975,289,505,440,883,277,824,000,000,000,000
That 52! number is the total number of ways to shuffle a standard deck of cards. It's a number so large that it exceeds the number of atoms on Earth. Every time you shuffle a deck, you are almost certainly creating an arrangement that has never existed in the history of the universe and will never exist again. The math is genuinely staggering.
This is why brute-force approaches fail for combinatorics problems. If you need to check every possible arrangement of 20 items, you're looking at 2.4 quintillion checks. Even at a billion operations per second, that's over 77 years. This is why computer scientists care so much about efficient algorithms ā sometimes there simply isn't enough time in the universe to try every possibility.
Frequently Asked Questions
Is a combination lock really a permutation?
Yes. Despite the name, a "combination lock" should technically be called a "permutation lock" because the order of the numbers matters. Entering 1-2-3 is different from 3-2-1 on a typical lock. You are selecting a permutation of numbers from a set, not a combination. The misnomer has stuck for over a century and shows no sign of going away.
When do I use nPr vs nCr?
Use nPr (permutations) when order matters and nCr (combinations) when order does not matter. Ask yourself: if I rearrange the selected items, does it count as the same result or a different one? Same result = combinations. Different result = permutations. Examples: arranging books on a shelf (permutations), choosing a committee (combinations), lottery numbers (combinations), passwords (permutations).
What does 52C5 mean?
52C5 means "choose 5 items from a set of 52, where order does not matter." This is the formula used to calculate the number of possible 5-card poker hands from a standard deck. The calculation is 52! / (5! Ć 47!) = 2,598,960 possible hands. Each specific hand (like a royal flush) is a tiny fraction of that total.
How do I calculate factorials of large numbers?
For numbers above 20, the factorial becomes extremely large (20! = 2.43 quintillion). For combinations and permutations, you rarely need to compute the full factorial. Instead, use the simplified formula that cancels terms. For example, 50C3 = (50 Ć 49 Ć 48) / (3 Ć 2 Ć 1) = 19,600. You only need to multiply the top 3 terms and divide by 3!, not compute 50!. For very large numbers, use a calculator or programming language that handles big integers.
Related Calculators
- Combination and Permutation Calculator ā Calculate nPr and nCr instantly
- Probability Calculator ā Find the probability of single and multiple events
- Exponent Calculator ā Calculate powers and roots of any number
- Scientific Calculator ā Full-featured calculator with factorial support
Want to check your work? Our combination and permutation calculator computes both nPr and nCr with a single input ā along with factorials, so you can verify each step of the calculation.
Nelson Chung
Independent developer with 10 years of software engineering experience. Passionate about math and finance, dedicated to making complex calculations simple and accessible.
Published April 20, 2026