Counting Without Counting: Permutations and Combinations
Imagine you have 10 friends and need to choose 3 to form a trivia team. Does it matter who is the captain, the buzzer-presser, and the researcher, or are you just picking any 3 people? The answer determines whether you need permutations (order matters) or combinations (order does not matter). These two counting techniques are among the most practical tools in all of mathematics, used in everything from lottery odds to password security to seating arrangements.
Our calculator handles both permutations and combinations. Enter the total number of items and how many you are choosing, and get the count instantly. No factorials to compute, no confusing notation, just the answer.
The key difference: If you are picking a president, vice president, and secretary from 10 club members, that is a permutation because ABC is different from BAC. But if you are just choosing 3 people to receive a prize, that is a combination because the order does not matter. The number of permutations is always greater than or equal to the number of combinations for the same values.
Permutations: When Order Matters
What is a permutation? A permutation counts how many different ways you can arrange items where the order makes a difference. Choosing a first-place, second-place, and third-place winner from 8 runners is a permutation. The number of permutations of n items taken r at a time is written as nPr and calculated as n factorial divided by (n minus r) factorial.
Factorials explained: A factorial, written with an exclamation mark, means multiply all positive integers up to that number. Four factorial (4!) = 4 x 3 x 2 x 1 = 24. Five factorial (5!) = 120. Factorials grow incredibly fast: 10! = 3,628,800 and 20! = 2,432,902,008,176,640,000. Factorials are the building blocks of both permutations and combinations.
Everyday permutation examples: Arranging 5 books on a shelf: 5! = 120 ways. Choosing a batting order of 9 players: 9! = 362,880 ways. Creating a 4-digit PIN code (assuming all digits can be reused): 10 x 10 x 10 x 10 = 10,000 ways. Picking the gold, silver, and bronze winners from 50 Olympians: 50P3 = 117,600 ways.
Combinations: When Order Does Not Matter
What is a combination? A combination counts how many different groups you can form when order does not matter. Choosing 3 friends for a movie outing from a group of 8 is a combination because the group of Alex, Ben, and Casey is the same as Casey, Alex, and Ben. The number of combinations of n items taken r at a time is written as nCr and calculated as nPr divided by r factorial.
Why combinations are fewer: Since order does not matter, combinations always give a smaller number than permutations. For 5 items taken 3 at a time, there are 60 permutations but only 10 combinations. This is because each combination of 3 items can be arranged in 3! = 6 different orders (permutations), and dividing 60 by 6 gives 10 combinations.
Everyday combination examples: Choosing 2 toppings from 10 available for your pizza: 10C2 = 45 possible pairs. Selecting 5 numbers from 1 to 69 for a lottery ticket: 69C5 = 11,238,513 possible combinations. Picking 3 colors from a box of 8 markers: 8C3 = 56 possible color sets. Choosing a committee of 4 from 15 classmates: 15C4 = 1,365 possible committees.
Lottery Odds: The Ultimate Combination Problem
Powerball explained: To win the Powerball jackpot, you must match 5 white balls from 69 and 1 red ball from 26. The number of possible combinations is 69C5 times 26 = 292,201,338. That means your odds of winning are 1 in about 292 million. To put that in perspective, you are more likely to be struck by lightning (1 in 15,300 in your lifetime), attacked by a shark (1 in 3.7 million), or become president (1 in 10 million) than to win the Powerball.
Why people still play: Even though the odds are astronomical, someone has to win eventually, and the excitement of a possible life-changing payout is worth the $2 ticket price to millions of people. Statistically speaking, buying a lottery ticket has a negative expected value, meaning you lose money on average. But for many players, the entertainment value and the dream make it worthwhile.
Smaller lotteries, better odds: A state lottery that requires picking 5 numbers from 1 to 40 has 40C5 = 658,008 possible combinations. Your odds of winning are 1 in about 658,000, which is much better than Powerball but still very unlikely. Scratch-off tickets typically have odds of about 1 in 4 for any prize, making them the most likely way to win something, even if the top prizes remain extremely rare.
Permutations and Combinations in Technology
Password security: A password with 8 characters, where each character can be any of 95 printable characters, has 95 to the 8th power = about 6.6 quadrillion possible combinations. This is why long passwords are so much more secure than short ones. Adding just one character multiplies the possibilities by 95. This is also why hackers use brute-force attacks that try combinations systematically.
License plates: A standard US license plate with 3 letters followed by 4 digits has 26 cubed times 10 to the 4th = 17,576,000 possible combinations. States need enough combinations to cover all registered vehicles. When a state runs out, it switches to a new format with more possible combinations.
Music playlists: If you have 100 songs and want to create a playlist of 10, there are 100C10 = about 17.3 trillion possible playlists. If each playlist lasts about 30 minutes and you listened to one every 30 minutes, it would take you over 33 million years to hear them all. The math of combinations explains why you will never run out of new music to discover.
Frequently Asked Questions
Permutations care about order, combinations do not. If you pick 3 letters from ABCD, ABC and ACB are different permutations (different order) but the same combination (same group). Use permutations when arrangement matters, like passwords, race results, or seating charts. Use combinations when only the group matters, like choosing a committee or lottery numbers.
The formula is n! / (r! x (n-r)!), where n is the total items and r is how many you are choosing. The exclamation mark means factorial, which is multiplying a number by every whole number below it. For choosing 3 from 10: 10! / (3! x 7!) = 120. Our calculator handles this for you, just enter the total and how many you want to pick.
A factorial (written with an exclamation mark) means multiply a number by every whole number below it down to 1. So 5 factorial (5!) = 5 x 4 x 3 x 2 x 1 = 120. Factorials grow extremely fast: 10! = 3,628,800. Factorials are used throughout permutations, combinations, and many areas of math because they count the number of ways to arrange items.
In a typical 6/49 lottery, you choose 6 numbers from 49. The number of combinations is 49! / (6! x 43!) = 13,983,816. That means there are nearly 14 million possible combinations, which is why hitting the jackpot is so rare. Your odds of winning are 1 in about 14 million, much lower than the chance of being struck by lightning.
Permutations apply whenever order matters. Creating a PIN code, arranging books on a shelf, scheduling a lineup of songs in a playlist, assigning seats at a wedding, or determining the order of runners in a relay race. For a playlist of 10 songs, there are 3,628,800 different orderings you could create.
nCr means the number of combinations of n items taken r at a time. nPr means the number of permutations of n items taken r at a time. The C stands for Combination and the P stands for Permutation. On many calculators, you will see these buttons. Our calculator lets you choose which one you need and computes both.
Because permutations count each arrangement separately while combinations group them together. For 3 items ABC, there are 6 permutations (ABC, ACB, BAC, BCA, CAB, CBA) but only 1 combination (ABC). The number of permutations equals the number of combinations multiplied by r factorial, since r items can be arranged in r! different ways.
Try More SupaCalc Tools
Free calculators for finance, health, AI costs, and more.
Browse All Calculators