Skip to main content
Categories
Table of contents

Permutation and combination calculator

Use this permutation and combination calculator to quickly find the number of possible arrangements or selections from a set of items. Permutations count ordered outcomes where sequence matters, while combinations count unordered groups where order does not matter. Simply enter the total number of items and the number selected to get results instantly.

Total amount in a set (n)
Amount in each sub-set (r)
Result
Permutations
nPr = = -
Combinations
nCr = = -

Related calculators:


Permutations and combinations

Permutations and combinations are two core concepts in combinatorics — the branch of mathematics that deals with counting how many ways objects can be arranged or selected from a set.

What they mean

  • Permutation
    A permutation is an arrangement of objects in which order matters. When you select a subset of elements from a set and the sequence in which they appear matters, you are counting permutations.
  • Combination
    A combination is a selection of objects where order does not matter. When you choose a subset and the order of selection is irrelevant, you are counting combinations.

Example:
From the set {A, B, C}, the permutations of two items include AB, BA, AC, CA, BC, and CB — because AB and BA are different when order counts.
The combinations of two items are AB, AC, and BC — because AB and BA are considered the same group.

Formulas

Let n be the total number of distinct items and r be the number selected.

Permutations (Order matters)

For permutations without replacement (no repeated elements), the number of ways to choose and arrange r items from n is:

_nP_r = \frac{n!}{(n - r)!}

Here, n! (n factorial) is the product of all positive integers up to n (e.g., 5! = 5×4×3×2×1).

Combinations (Order doesn’t matter)

For combinations without replacement, the formula is:

_nC_r = \frac{n!}{r! \times (n - r)!}

This is also written as “n choose r” and counts the number of unique groups of size r that can be chosen from n.

How it works

Permutation Example (Order Matters)

How many different 4-digit access codes can be created from the digits 1 through 8 if no digit can be used more than once?

In this case, the order of the digits matters, since the code 1234 is different from 4321.

  • Total digits available: n=8n = 8
  • Digits chosen: r=4r = 4
_{8}P_{4} = \frac{8!}{(8 - 4)!} = 8 \times 7 \times 6 \times 5 = 1{,}680

So, there are 1,680 different possible access codes.

Combination example (Order does not matter)

How many different study groups of 3 students can be formed from a class of 12 students?

Here, order does not matter. A group consisting of Alice, Ben, and Carol is the same group regardless of the order in which their names are listed.

  • Total students: n=12n = 12n=12
  • Group size: r=3r = 3r=3
_{12}C_{3} = \frac{12!}{3! \times (12 - 3)!} = 220

There are 220 unique study groups that can be formed.

Why the results are different

Notice that the permutation example produces a larger number because each unique ordering is counted separately. In contrast, the combination example counts each group only once, regardless of arrangement.

Another intuitive comparison

  • Selecting three songs to play in a specific orderPermutation
  • Selecting three songs to include in a playlistCombination

Notes on replacement

The calculator on this page handles only the case without replacement. That means once an item is chosen, it cannot be chosen again in the same selection.

  • Permutations with repetition (where chosen items can repeat) use a different formula: n^r
  • Combinations with repetition use: \binom{n+r-1}{r}

These cases are not included in the permutation/combination counts above.

When to use which

ScenarioUse
Order matters (arrangements, sequences, ranks)Permutation
Order doesn’t matter (groups, teams, selections)Combination

Summary

  • Permutations count ordered arrangements.
  • Combinations count unordered selections.
  • The core difference is whether order influences your count.