Combination Calculator

Inputs
Common calculations
Result
Your result
84
C(9, 3) = 9! / (3! x 6!)
= 9 x 8 x 7 / (3 x 2 x 1)
= 84
Pascal's triangle — C(9, 3) highlighted
Open full triangle

What is a combination?

A combination C(n, k) is the number of ways to choose k items from n when order does not matter. The same quantity is also written nCr or C(n, r); this page uses k to match the inputs.

SymbolMeaning
nTotal number of items
kNumber of items selected
C(n, k)Number of combinations

If order matters, that is a permutation: P(n, k) = C(n, k) x k!. For n! see the factorial calculator.

Formula

C(n, k) = n! / (k! x (n-k)!)

C(n, k) = C(n, n-k). This calculator uses k everywhere.

Limitations

k must be an integer between 0 and n; k > n is invalid, not zero. n is capped at 170. Direct n! overflows quickly; the engine multiplies the k terms (n x (n-1) x ... x (n-k+1)) / k! instead of building full factorials.

Sampling with replacement is a different formula and is not modeled here.

FAQ

What is C(n, k)?

Ways to choose k items from n without regard to order. Also written nCr.

Combination vs permutation?

Combinations ignore order. Permutations count each ordering: P(n, k) = C(n, k) x k!.

What is C(52, 5)?

2,598,960 five-card poker hands. Use the poker preset above to load it.