Calculate permutations (nPr) and combinations (nCr).
Calculated locally in your browser.
How do you calculate permutations and combinations?
nPr = n! ÷ (n − r)! counts ordered arrangements, and nCr = n! ÷ (r! × (n − r)!) counts unordered selections. Permutations are always at least as many as combinations because order adds extra arrangements. For example, from 5 items choosing 2 gives 10 combinations (5C2) and 20 permutations (5P2).
Understanding your result
Permutations are always at least as many as combinations, because order adds extra arrangements.
Formula and method
nPr = n! ÷ (n − r)! counts ordered arrangements. nCr = n! ÷ (r! × (n − r)!) counts unordered selections.
Assumptions and limitations
This tool needs whole numbers with r no greater than n and both non-negative; other inputs have no defined result. Factorials grow extremely fast, so very large values of n may exceed standard numeric precision and be shown in approximate form. It counts arrangements only and assumes distinct items chosen without repetition, not selections that allow repeats.
Worked example
From 5 items choosing 2: 10 combinations (5C2) and 20 permutations (5P2).
How to use this tool
- Enter n (total items) and r (how many you choose).
- Read both nCr and nPr.
Common mistakes to avoid
- Using r greater than n — you cannot choose more items than you have.
About the Permutations & Combinations
Calculate how many ways you can choose or arrange items: combinations (order does not matter) and permutations (order matters).
Who should use this tool
Students and anyone working with probability or counting problems.
Benefits
- Calculates both nPr and nCr from one set of inputs
- Clarifies when order matters and when it does not
- Handles the factorial arithmetic instantly and accurately
- Runs in your browser with no installation or sign-up
Practical use cases
- Counting lottery or raffle combinations quickly
- Working out seating or ranking arrangements
- Solving probability and combinatorics coursework
- Estimating password or code space sizes
Frequently asked questions
What is the difference between nPr and nCr?
nPr counts ordered arrangements; nCr counts unordered selections.
What is the largest n supported?
Up to 170, beyond which factorials exceed the number range.
Does this count selections that allow repeats?
No. The standard nPr and nCr formulas assume each item is chosen at most once and that all items are distinct. Problems that permit repetition, such as choosing scoops of the same ice-cream flavour, use different formulas for permutations and combinations with repetition, which this tool does not calculate.