Permutation Calculator (nPr)
Calculate permutations — arrangements of items
What is it?
A permutation counts the number of ways to arrange r items chosen from a set of n items, where the order of selection matters.
Formula
nPr = n! / (n − r)!
Formula Explanation
Dividing n! (all possible orderings of n items) by (n−r)! removes the orderings of the items you didn't select, leaving only the count of ways to arrange the r chosen items in sequence.
Example Calculation
5P2 = 5! / 3! = 120 / 6 = 20 ways to arrange 2 items chosen from 5.
How to Use
- Enter the total number of items (n).
- Enter the number of items being arranged (r).
- Click Calculate nPr to see the number of possible arrangements.
Benefits
- Instantly computes exact arrangement counts without manual factorial division.
- Shows the formula substitution step for learning purposes.
- Validates inputs to prevent invalid r > n calculations.
Use Cases
- Counting the number of ways to award 1st, 2nd, and 3rd place in a race.
- Password or PIN arrangement counting problems.
- Probability problems where the order of outcomes matters.
What Your Result Means
The result is the exact number of distinct ordered arrangements possible when selecting r items from a set of n, where swapping the order of two selected items counts as a different arrangement.
Tips
- Use permutation when order matters (like rankings); use combination when it does not (like groupings).
- When r = n, nPr simplifies to n! (arranging all items).
- When r = 0, nPr always equals 1 (there's exactly one way to arrange nothing).
Common Mistakes
- Using permutation when the problem actually describes an unordered selection (that's a combination).
- Entering r greater than n, which describes an impossible selection.
- Forgetting that swapping two items in a permutation creates a distinct arrangement.
FAQs
How is permutation different from combination?
Permutation counts arrangements where order matters (like race finish positions), while combination counts selections where order doesn't matter (like choosing a team).
What does nPr mean?
nPr reads as "n permute r" — the number of ways to arrange r items selected from a total of n distinct items.
What happens if r equals n?
When r = n, nPr equals n! — the number of ways to arrange all n items in a sequence.
What is nPr when r = 0?
nPr equals 1 when r = 0, since there is exactly one way to arrange zero items (doing nothing).
Where are permutations used in real life?
Permutations are used in scheduling, ranking systems, password/combination lock counting, and any scenario where the sequence of selection matters.
Results are exact for n up to 170, limited by JavaScript number precision.
Last updated: July 25, 2026