全球免费使用

排列组合计算器(nPr、nCr)

精确计算排列 nPr 和组合 nCr,可选是否允许重复,n 最大 1,000。

你的数据只保留在此标签页中。我们不会收到你的文件、粘贴的文本或计算数值。

输入

提示:按 Ctrl + Enter 运行

你的结果

结果将显示在这里。

下方的详细帮助目前仅提供英文版。

关于此工具

How many ways can a committee be chosen, a password be formed or a lottery ticket be filled? Permutations count arrangements where order matters; combinations count selections where it does not. This calculator gives both for n items taken r at a time, with or without repetition, using exact big-integer arithmetic so even huge counts are precise.

使用方法

  1. Enter n, the number of items to choose from.
  2. Enter r, the number chosen.
  3. Choose whether repetition is allowed.
  4. Run it and use permutations if order matters, combinations if it does not.

计算原理

Without repetition: nPr = n! ÷ (n − r)! and nCr = n! ÷ (r! (n − r)!). With repetition: permutations = n^r and combinations = (n + r − 1)! ÷ (r! (n − 1)!). All values are computed with exact integers.

nPr = n! ÷ (n − r)!; nCr = n! ÷ (r! (n − r)!)

计算示例

A 6/49 lottery picks 6 numbers from 49 without repetition and order does not matter: there are 13,983,816 combinations, so one ticket has about a 1 in 14 million chance. If order mattered there would be 10,068,347,520 permutations. A 4-digit PIN (digits can repeat) has 10,000 permutations.

示例输入和结果

元素总数(n): 10
选取个数(r): 3
允许重复: 否

→ 排列(考虑顺序): 720
→ 组合(不考虑顺序): 120

局限性

  • n and r up to 1,000.
  • No restrictions such as "at least one of each type".
  • Results are counts, not lists of arrangements.

最后更新:

常见问题

When does order matter?

For rankings, seats, passwords and race results, order matters (permutations). For teams, hands of cards and lottery tickets, it does not (combinations).

What if r is larger than n?

Without repetition there are no ways to choose, so the result is 0; with repetition it is allowed.

Why are some results so large?

Factorials grow very fast; the calculator keeps every digit.

故障排除

The answer is 0.

r is greater than n without repetition.

My probability looks wrong.

Probability of one outcome = 1 ÷ the number of equally likely outcomes; check you used combinations vs permutations correctly.

A textbook gets a different count for repetition.

Check whether the problem allows repetition and whether order matters.

隐私 & 免费使用

我的输入会被保存吗?

你的数据只保留在此标签页中。我们不会收到你的文件、粘贴的文本或计算数值。

这个工具免费吗?

是的。无需注册或付费。

在浏览器中处理

推荐下一步