# Permutation & Combination Calculator

> Compute nPr and nCr, with optional listing of all arrangements or subsets. Bounded for huge counts.

URL: https://uttir.com/permutation-combination
Categories: math-tools, calculators
Privacy: All calculations run locally in your browser. Nothing is uploaded — close the tab and the data is gone.

## About

Permutations and combinations are the two basic ways of counting selections from a set. A permutation is an ordered arrangement — picking 1st, 2nd, 3rd place. A combination is an unordered subset — picking a committee of three.

This tool computes nPr and nCr instantly, formats the result with sensible magnitude (3.7 million, 1.2 × 10²⁴, etc.), and — for small enough values — lists every arrangement or subset so you can see the pattern.

## How to use

1. **Enter n and r** — n is the total set size, r is how many you pick.
2. **Pick permutation or combination** — Permutation counts order, combination does not.
3. **Optionally list the values** — Enter items as a comma-separated list, then click List to enumerate.

## Examples

### Lottery odds

6 numbers from 49, order does not matter.

Input:

```
n = 49, r = 6, combination
```

Output:

```
13,983,816 (≈ 14 million)
```

### Race podium

1st, 2nd, 3rd from 8 runners, order matters.

Input:

```
n = 8, r = 3, permutation
```

Output:

```
336 (8 × 7 × 6)
```

## FAQ

### What is the difference?

Permutation counts arrangements where order matters (race positions). Combination counts subsets where order does not (a committee). The formula is the same except combinations divide by r! to remove the ordering.

### Why does my count say "1.2 × 10²⁴"?

For large n and r the count is bigger than JavaScript can hold exactly. We use the magnitude (log₁₀) to keep the number readable, and the answer is still correct — just not a 64-bit integer.

### Why is the list limited?

Listing all permutations of 20 items is 2.4 × 10¹⁸ — far more than any browser can render. The list is capped at 50,000 entries; for larger inputs we show the count and a sample instead.

## Related tools

- [Statistics Calculator](https://uttir.com/statistics-calculator) — Compute mean, median, mode, range, variance, standard deviation, and quartiles from a list of numbers.
- [Percentage Calculator](https://uttir.com/percentage-calculator) — Three percentage tools in one: percent of a value, ratio as a percent, and percent change.
- [Random Number Generator](https://uttir.com/random-number-generator) — Pick a random number, roll dice, or shuffle a list. Cryptographically secure, runs locally.

---

For the full HTML page with the live tool, visit https://uttir.com/permutation-combination.
This file is the markdown rendering at https://uttir.com/permutation-combination.md. See https://uttir.com/llms.txt for a site-wide summary.
