Skip to main content
CalcChef

Permutation and Combination Calculator

Counts permutations nPr and combinations nCr for n and r up to 1000, with or without repetition. Every digit is exact and the formula is worked through. How it works

Use the Permutation and Combination Calculator

Whole numbers from 0 to 1000. Every digit of the result is exact, with no rounding.

Repetition

Writes out the selections themselves (up to 300) for n up to 26.

Permutations
P(10, 3) = 720
Combinations C(10, 3) = 120

Permutations (order matters)

P(10, 3) = 720

3 digits

  1. P(n, r) = n! / (n − r)!
  2. = 10! / (10 − 3)! = 10! / 7!
  3. = 10 × 9 × 8 = 720

Combinations (order doesn't matter)

C(10, 3) = 120

3 digits

  1. C(n, r) = n! / (r! × (n − r)!)
  2. = 10! / (3! × 7!)
  3. = P(10, 3) / 3! = 720 / 6 = 120

Pascal's triangle: C(n, r) for n up to 10

n \ r012345678910
01not definednot definednot definednot definednot definednot definednot definednot definednot definednot defined
111not definednot definednot definednot definednot definednot definednot definednot definednot defined
2121not definednot definednot definednot definednot definednot definednot definednot defined
31331not definednot definednot definednot definednot definednot definednot defined
414641not definednot definednot definednot definednot definednot defined
515101051not definednot definednot definednot definednot defined
61615201561not definednot definednot definednot defined
7172135352171not definednot definednot defined
818285670562881not definednot defined
9193684126126843691not defined
101104512021025221012045101

About the Permutation and Combination Calculator

P(10, 3) = 720 and C(10, 3) = 120: there are 720 ways to arrange 3 of 10 items in order, and 120 ways to choose 3 when order does not matter. This permutation and combination calculator gives both counts for any n and r up to 1000, with or without repetition, and shows the formula with your numbers in it. For n up to 26 it also lists the selections themselves, up to 300 of each: P(3, 2) is AB, AC, BA, BC, CA and CB.

nPr and nCr for n = 5 to 12

nP(n, 2)C(n, 2)P(n, 3)C(n, 3)P(n, 4)C(n, 4)
5201060101205
630151202036015
742212103584035
85628336561,68070
97236504843,024126
1090457201205,040210
11110559901657,920330
12132661,32022011,880495

P counts ordered arrangements and C counts unordered groups, so P(n, r) is always C(n, r) × r!.

Counts people look up

What is countedFormulaCount
5 cards from a 52-card deckC(52, 5)2,598,960
13 cards from a 52-card deckC(52, 13)635,013,559,600
6 numbers from 49C(49, 6)13,983,816
5 numbers from 69C(69, 5)11,238,513
3 people from a group of 10C(10, 3)120
First, second and third among 10P(10, 3)720
Orders of 5 books on a shelfP(5, 5)120
4-digit PIN, digits may repeat10^410,000
3-letter code from 26 letters, letters may repeat26^317,576

Choosing 3 from 10 under each counting rule

Order mattersRepetition allowedFormulaCount
YesNoP(10, 3)720
YesYes10^31,000
NoNoC(10, 3)120
NoYesC(12, 3)220

With repetition the combination count is C(n + r − 1, r), which is why the last row reads C(12, 3).

How to use this tool

  1. Type n, the number of items to choose from, and r, the number you pick. Both are whole numbers from 0 to 1000.
  2. Leave Without repetition selected if each item can be picked only once, or choose With repetition if it can be picked again.
  3. Read the permutations (order matters) and the combinations (order does not matter). Each card shows its working, and a result longer than 15 digits can be copied in full.
  4. For small counts, read C(n, r) straight off the Pascal’s triangle table under the results, which covers n from 0 to 10, or press List the arrangements to see the selections written out with the items named A, B, C and so on.

Frequently asked questions

What is the difference between a permutation and a combination?
A permutation counts ordered arrangements and a combination counts unordered groups. Picking 2 letters from A, B and C gives 6 permutations (AB, BA, AC, CA, BC, CB) and 3 combinations (AB, AC, BC), which List the arrangements writes out for n = 3 and r = 2. Each group of r items can be put in r! orders, so P(n, r) = C(n, r) × r!.
What is 5 choose 2?
10. C(5, 2) = 5! ÷ (2! × 3!) = 20 ÷ 2 = 10. The same inputs give P(5, 2) = 5 × 4 = 20 ordered pairs.
How many 5-card poker hands are there?
2,598,960. That is 52 choose 5: the order of the cards does not matter and no card repeats. Counting the order in which the cards are dealt gives P(52, 5) = 311,875,200.
How many combinations are there in a lottery that draws 6 numbers from 49?
13,983,816. That is C(49, 6), so a single ticket matches all six numbers with a chance of 1 in 13,983,816.
How do I count when items can repeat?
Choose With repetition. Ordered picks become n^r: a 3-letter code from 26 letters has 26^3 = 17,576 possibilities. Unordered picks become C(n + r − 1, r): 3 scoops from 10 ice cream flavors, with repeats allowed, is C(12, 3) = 220.
What are C(n, 0) and 0!?
0! is 1, so C(n, 0) = 1 and P(n, 0) = 1: there is exactly one way to choose nothing. The tool also gives C(0, 0) = 1.

Related Tools

View all tools