Permutation & Combination Calculator

Calculate nPr (permutations) and nCr (combinations) with step-by-step factorial breakdowns. Everything runs in your browser — nothing is stored or sent to any server.

Ad Space

How Permutation & Combination Calculator Works

Calculate permutations and combinations instantly with step-by-step factorial breakdowns. runs in your browser. Enter your values into the form above and the calculator processes them instantly in your browser — no data is sent to any server.

Understanding Permutations and Combinations

Permutations and combinations are fundamental counting techniques in mathematics used to determine the number of possible arrangements or selections from a set of items. They appear everywhere — from probability and statistics to cryptography, genetics, and game theory.

The key distinction is straightforward: permutations care about order, while combinations do not. Choosing Alice, Bob, and Carol for president, vice-president, and treasurer is a permutation problem (ABC differs from BAC). Choosing 3 people for a committee is a combination problem (the same group regardless of order).

Formulas

Permutation: nPr = n! / (n - r)!

Combination: nCr = n! / [r! × (n - r)!]

Where:

  • n = total number of items
  • r = number of items chosen
  • n! = n factorial = n × (n-1) × (n-2) × ... × 1

Real-World Examples

Permutation vs Combination: Quick Rule

Ask yourself: "Does the order in which I pick items change the outcome?" If yes, use permutations. If no, use combinations. For instance, a PIN code 1234 is different from 4321 (permutation), but a hand of cards {A, K, Q} is the same regardless of draw order (combination).

Factorials Explained

A factorial (written as n!) is the product of all positive integers from 1 to n. For example, 5! = 5 × 4 × 3 × 2 × 1 = 120. By convention, 0! = 1. Factorials grow extremely fast — 20! is already over 2.4 quintillion. This calculator handles values up to n = 170 before JavaScript number precision limits are reached.

Applications

Combinatorics underpins probability theory, statistical sampling, algorithm design (sorting, hashing), error-correcting codes, DNA sequencing, and tournament scheduling. Understanding permutations and combinations is essential for standardised tests like the GRE, GMAT, SAT, and competitive programming contests.