Permutation & Combination Calculator
Count how many ways r items can be chosen from a set of n. The hard part of this problem is never the arithmetic — it is deciding whether the order matters and whether an item can be picked twice — so all four answers are shown at once: combinations, permutations, and each of those again with repetition allowed. Every result is an exact whole number however large it gets, computed multiplicatively rather than by dividing one factorial by another, which is what stops the intermediate values overflowing long before the answer would. That means 100 choose 50 comes out in full rather than as a rounded value in scientific notation.
How it works
Choose r items from a set of n. The two questions to settle first: does the order they come out in matter, and can the same item be picked twice? Those two answers pick the formula — all four are shown below so you can see what the other choices would have given.
Answers are exact whole numbers however large they get, so 100C50 is not rounded off into scientific notation.
All four ways of counting
The same n and r under each of the four rules.
Details
Frequently asked questions
What is the difference between a permutation and a combination?
Order. A permutation counts arrangements, so ABC and CBA are different; a combination counts selections, so they are the same. Picking a race podium is a permutation; picking a poker hand is a combination.
When should I allow repetition?
When the same item can be chosen more than once — a four-digit PIN can repeat digits, whereas dealing cards from a deck cannot.
How large can n and r be?
Up to 100,000 each. Answers are exact whole numbers of unlimited length, so a result with hundreds of digits is shown in full.
Why do I get an error when r is larger than n?
Without repetition you cannot choose more items than exist. Switch to one of the with-repetition modes and r may exceed n freely.
What is nCr used for?
Binomial coefficients, lottery and card probabilities, and any question of the form "how many ways can I pick k things from n" where the order of picking does not matter.
Is the calculation done on my device?
Yes. Nothing you enter is sent anywhere.
Related tools
Scientific Calculator
Type a whole expression and watch it resolve as you go — powers, roots, logs, trigonometry and factorials.
Big Number Calculator
Exact arithmetic on whole numbers of any length — far past the point where ordinary calculators start rounding.
Statistics Calculator
Paste a column of numbers and get mean, median, mode, standard deviation, quartiles and outliers at once.