Skip to content
BestCalculators
Free online calculators and converters

Education & Grades

Permutation and Combination Calculator: nPr and nCr

Work out combinations and permutations together, with and without repetition, so you can see which one your question is actually asking for.

The pool. Above 170 the factorials stop fitting in a computer’s number, which is a real limit rather than an arbitrary one.

Picking more than the pool holds gives zero, because there is genuinely no way to do it.

Combinations — order does not matter

13,983,816

Choosing 6 from 49 when the order is irrelevant. There are 10,068,347,520 permutations of the same choice, which is 720 times as many.

Permutations — order matters
10,068,347,520

Always the larger of the two, because every combination can be shuffled into several different orders and each one counts separately.

How many orderings each combination has
720

Exactly r factorial. Dividing the permutations by this is what turns them into combinations — that is the whole difference between the two.

Combinations with repetition allowed
25,827,165

When you can pick the same thing twice — scoops of ice cream, coins from a jar. Larger than plain combinations, because repeats add cases rather than removing them.

Permutations with repetition allowed
13,841,287,201

Simply n to the power of r. This is the one that counts PIN codes and passwords, where each position is independent of the others.

Chance of one specific combination
0.00000715%

One ticket against every possible draw. Buying a second ticket doubles a number this small and still leaves it this small.

Stated as one in
13,983,816

The form odds are usually quoted in, and the reason a 6-from-49 draw is so hard to win.

n factorial
608,281,864,034,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000

Every possible ordering of the entire pool. It grows faster than almost anything else in mathematics.

r factorial
720
Combinations of the ones you leave behind
13,983,816

Identical to the answer above. Choosing 6 from 49 is the same act as choosing which 43 to reject, which is a useful shortcut when r is large.

Total subsets of the pool
562,949,953,421,000

Every item is either in or out, so it is 2 to the power of n. Summing the combinations across every possible r gives exactly this.

How to use this calculator

  1. Enter the size of your pool into the n field labeled 'How many things to choose from'.
  2. Enter the number of items you are selecting into the r field labeled 'How many you pick'.
  3. Review the headline result for Combinations where order does not matter, calculated via the nCr calculator formula.
  4. Examine the extended outputs below the main result, including Permutations (nPr calculator), factorials, and repetition scenarios.

Understanding Combinations and Permutations

When solving discrete mathematics problems, the single most critical distinction lies in whether the sequence of selection changes the outcome. A combination calculator addresses scenarios where grouping is all that matters, such as selecting a committee of three people from a pool of ten. In contrast, an npr calculator handles situations where the exact arrangement defines a unique outcome, such as the digits in a bicycle lock combination or finishing positions in a race.

The underlying mathematics for combinations and permutations relies heavily on factorials. The standard combination formula is expressed as nCr = n! ÷ (r! × (n − r)!), which removes duplicate selections caused by different orderings of the exact same items. Meanwhile, the permutation formula is nPr = n! ÷ (n − r)!. The tool quietly computes the ratio between these two metrics by evaluating nPr = nCr × r!, revealing precisely how many distinct orderings each combination contains.

How Repetition Changes the Math

Most introductory math problems assume items are drawn without replacement, meaning once an object is picked, it vanishes from the pool. However, real-world constraints frequently permit items to be selected multiple times. When repetition is allowed, the formula shifts to C(n+r−1, r) for combinations and for permutations. This adjustment drastically expands the solution space, particularly when the sample size is modest but the number of picks is large.

Consider selecting ice cream scoops from a menu of thirty flavors where you can double up on your favorite flavor. A standard combination calculator without replacement would severely restrict your choices, whereas the repetition variant accommodates identical selections. The tool evaluates these variations side-by-side so you can instantly verify which mathematical model matches the exact rules of your problem.

Interpreting Extended Outputs and Probabilities

Beyond basic group sizing, advanced problem-solving requires examining complementary subsets and odds. The tool automatically computes the factorial calculator outputs for both n! and r!, alongside the combinations of the items you leave behind via nCr(n, n - r). Symmetrical properties dictate that choosing r items from n yields the exact same count as leaving n - r items behind.

Furthermore, the output panel converts raw counts into practical risk metrics. By dividing one by the total combinations, the system displays the exact percentage chance of hitting one specific combination, as well as stating the odds as a ratio of one in a million or billion. Finally, the total subsets of the pool is calculated using pow(2, n), representing the complete power set of the original group.

Reference Table of Common Values

Pool (n)Pick (r)Combinations (nCr)Permutations (nPr)Total Subsets
53106032
10245901,024
10525230,2401,024
50615,890,70011,418,916,8001,125,899,906,842,624

Avoiding Common Calculation Mistakes

A frequent pitfall when using an ncr calculator is misidentifying whether a problem requires combinations or permutations. If a user treats a password security problem as a combination when order strictly matters, they will drastically underestimate the security strength. Always verify whether rearranging your chosen items creates a distinct scenario before locking in your mathematical approach.

Another error involves violating domain bounds. Picking more items than the pool holds (where r > n) yields zero combinations because there is genuinely no physical way to execute the selection. When zero results appear, check your input fields to ensure your sample pool is larger than your selection target.

The formula

nCr = n! ÷ (r! × (n − r)!) order does not matternPr = n! ÷ (n − r)! order mattersnPr = nCr × r! the ratio between themwith repetition: C(n+r−1, r) and nʳ

Frequently asked questions

What is the difference between a combination and a permutation?

The primary difference is whether the internal order of selected items matters to the final outcome. Combinations group items where sequence is irrelevant, whereas permutations treat every distinct ordering as an entirely unique arrangement. For example, a lottery draw uses combinations, while a padlock code requires a strict permutation.

Why does the calculation fail when n is greater than 170?

Factorials grow exponentially larger with every integer added to the pool. When n exceeds 170, the resulting factorial value exceeds the maximum floating-point limit supported by standard computer architecture. This limitation is a hard mathematical constraint of digital computing rather than a flaw in the software.

What happens if I try to pick more items than exist in the pool?

If your selection value for r is greater than your pool size n, the equation returns zero. This occurs because it is physically impossible to select five unique items from a pool containing only four items. Always ensure your pool size equals or exceeds your pick count.

How do I calculate combinations with repetition allowed?

When items can be chosen more than once, the standard formula is modified to account for replacement. The tool uses the expanded formula C(n+r-1, r) for combinations with repetition, and n to the power of r for permutations with repetition. This correctly expands the total outcome space to accommodate duplicate selections.

Can I trust these mathematical results for complex statistical analysis?

Yes, the calculations follow strict, universally accepted combinatoric formulas without approximation. However, if you are conducting advanced probabilistic modeling or academic research involving massive datasets, you should consult a statistician or specialized mathematical software to handle precision limits.

Sources

Last reviewed . Results are for general guidance and are not professional advice.