Combinatorics calculator

Combination Calculator

Find how many ways r items can be chosen from n items when order does not matter.

Enter values

Enter values and select Calculate.

Formula and method

For 0 ≤ r ≤ n, C(n,r) = n! / (r!(n−r)!). The engine uses k = min(r,n−r) and exact iterative BigInt multiplication and division, avoiding floating-point factorial division.

Worked example

Choosing 3 people from 10 gives C(10,3) = 120. Because order does not matter, C(10,3) also equals C(10,7).

Inputs and boundaries

  • n and r must be nonnegative integers, with r no greater than n.
  • The calculation is without repetition.
  • Inputs are limited to 10,000 to keep very large results responsive.
  • The full exact integer is returned; no floating-point precision is lost.

Inputs and results stay in this browser and are not sent to analytics, storage, URLs, or network services.