Use this free online permutation and combination calculator to compute the number of ways to arrange or select items from a set. Enter your values for n (total items) and r (items chosen), pick whether order matters, and get your answer instantly.
Permutations count arrangements where order is important. Combinations count selections where order does not matter. This calculator handles both, with or without repetition, so you can solve probability homework, plan tournaments, or figure out how many unique passwords are possible from a given set of characters.
How to Calculate Permutations and Combinations
Start by identifying two numbers:
- n: the total number of objects in your set
- r: the number of elements you want to choose or arrange
Then ask one question: does order matter?
- If yes, you need a permutation.
- If no, you need a combination.
For example, choosing 3 prize winners from 10 contestants where 1st, 2nd, and 3rd place are different is a permutation. Choosing 3 people for a committee (no ranking) is a combination.
Once you know n, r, and whether order matters, plug the values into the calculator above or apply the formulas below by hand.
Permutation Formula
A permutation counts the number of arrangements of r elements from a set of n distinct objects. The standard permutation equation is:
P(n, r) = n! / (n − r)!
The exclamation mark means factorial. It is the product of all positive integers up to that number. So 5! = 5 × 4 × 3 × 2 × 1 = 120.
How many permutations are there for selecting 3 balls out of 5 balls without repetitions? Apply the formula:
P(5, 3) = 5! / (5 − 3)! = 120 / 2 = 60
There are 60 unique ways to arrange 3 balls chosen from 5 when each ball can only be used once.
Combinations Formula
A combination counts the number of ways to choose r elements from a set of n objects when the order does not matter. The combinations formula is:
C(n, r) = n! / [r! × (n − r)!]
This is also written as "n choose r." The extra r! in the denominator removes duplicate arrangements.
How many different combinations of 2 prizes could you possibly choose from 5 options?
C(5, 2) = 5! / (2! × 3!) = 120 / (2 × 6) = 10
Ten different combinations are possible.
nCr: the Combination Calculator
The notation nCr is shorthand for "from n, choose r." It is the same as the combinations formula above. You may also see it written as a binomial coefficient in parentheses.
In the calculator, select the combination mode, enter n and r, and the tool returns nCr directly. This is useful for problems like:
- How many 5 card poker hands can be dealt from a 52 card deck? C(52, 5) = 2,598,960
- How many ways can you pick 3 team members from 12 people? C(12, 3) = 220
What does n and r mean in combinations? Simply put, n is the size of the full set and r is how many you select.
Permutation Calculator With Repetition
Sometimes you can reuse items. A 4 digit PIN where each digit can be 0 through 9, and digits can repeat, is a permutation with repetition.
The formula is:
n^r
For a 4 digit PIN with 10 possible digits: 10^4 = 10,000 possible permutations.
If each time we select a ball we place it back in the bag, how many unique permutations will we have when choosing 3 from 5? That is 5^3 = 125.
Use the repetition toggle in the calculator to switch to this mode.
Combination Calculator With Repetition
Combinations with repetition apply when you can choose the same item more than once and order does not matter. Think of an ice cream shop where you pick 3 scoops from 5 flavors and you can repeat a flavor.
The formula is:
C(n + r − 1, r) = (n + r − 1)! / [r! × (n − 1)!]
Calculate the Total Number of Selections
For 3 scoops from 5 flavors with repetition allowed:
C(5 + 3 − 1, 3) = C(7, 3) = 35
There are 35 possible combinations when replacements are allowed. How many combinations are possible if customers are also allowed replacements when choosing toppings? Use the same approach: plug the number of topping choices and the number of picks into this formula.
Number of Ways Without Repetition
Without repetition, the same problem uses the standard combinations formula:
C(5, 3) = 10
The difference is significant. Allowing repetition nearly quadrupled the number of selections in this example. The calculator lets you toggle repetition on or off to compare both results side by side.
Combinations and Permutations: When Order Matters
The core difference between permutations and combinations is whether the arrangement matters.
- Permutation: the sequence ABC is different from BAC. Order is important.
- Combination: ABC and BAC count as the same selection. Order does not matter.
A practical test: if swapping two chosen items creates a meaningfully different outcome (like finishing 1st vs. 2nd in a race), use a permutation. If swapping changes nothing (like picking teammates), use a combination.
What is the difference between permutation and combination in one sentence? Permutations count ordered arrangements; combinations count unordered selections.
Factorial in the Permutation and Combination Formula
Factorial (n!) is the engine behind both formulas. It calculates the total number of arrangements for n distinct objects in a line.
Quick reference:
- 0! = 1 (by definition)
- 1! = 1
- 5! = 120
- 10! = 3,628,800
Large factorials grow fast. That is why a calculator is handy. Computing 52! by hand is not practical, but the tool handles it instantly.
Binomial Coefficient and nCr
The binomial coefficient is the mathematical name for nCr. It appears in the binomial theorem, probability distributions, and many areas of discrete mathematics.
The notation looks like this in textbooks: a column with n on top and r on the bottom, enclosed in parentheses. It equals C(n, r) = n! / [r! × (n − r)!].
You will see it called "n choose r" or "n choose k" interchangeably. Both mean the same calculation. The permutation and combination calculator on this page computes the binomial coefficient whenever you select combination mode.
Calculate Permutations and Combinations Step by Step
Follow these steps to solve any problem by hand or verify your calculator result:
- Identify n (total items) and r (items to choose).
- Decide if order matters (permutation) or not (combination).
- Decide if repetition is allowed.
- Pick the correct formula from the table below.
- Compute the factorial values and divide.
| Scenario | Formula |
|---|---|
| Permutation without repetition | n! / (n − r)! |
| Permutation with repetition | n^r |
| Combination without repetition | n! / [r! × (n − r)!] |
| Combination with repetition | (n + r − 1)! / [r! × (n − 1)!] |
Permutation Calculator Examples
Example 1: Race finishes. 8 runners compete. How many different ways can the top 3 finish?
P(8, 3) = 8! / 5! = 8 × 7 × 6 = 336 arrangements.
Example 2: Password from letters. You want a 4 character password from 26 lowercase letters, and letters can repeat.
26^4 = 456,976 possible permutations.
Example 3: Seating. How many ways can you seat 6 people in 6 chairs?
P(6, 6) = 6! = 720 number of arrangements.
Combination Calculator Examples
Example 1: Lottery selection. Pick 6 numbers from 49. Order does not matter.
C(49, 6) = 13,983,816 possible combinations.
Example 2: Handshakes. 10 people are in a room. Each person shakes hands once with every other person. What is the total number of handshakes?
C(10, 2) = 45 handshakes.
Example 3: Sandwich combos. A menu offers 8 toppings. You choose 3. How many sandwich combinations are possible?
C(8, 3) = 56 different combinations.
How do I calculate combinations from permutations? Divide the permutation result by r! to remove the ordering. C(n, r) = P(n, r) / r!.
When to Use This Permutation and Combination Calculator
This tool helps whenever you need to find the number of ways to select or arrange items. Common uses include:
- Probability and statistics problems: finding the total number of possible outcomes
- Combinatorics homework: verifying step by step work
- Password strength estimates: calculating the number of unique permutations for a given length and character set
- Planning and logistics: seating charts, team assignments, tournament brackets
- Lottery odds: computing how many different combinations exist for a drawing
The results are mathematical estimates based on the formulas above. For statistical problems tied to professional decisions (financial modeling, clinical research), consult a qualified expert.
Enter your n and r values in the calculator at the top of the page to compute the number of possible permutations or combinations instantly.