Skip to content

The fundamental counting principle

5 min read

Short answer

If a process has several stages and stage 1 can be done in n1n_1 ways, stage 2 in n2n_2 ways, and so on, then the whole process can be done in n1×n2×⋯×nkn_1\times n_2\times\cdots\times n_k ways. The stages must be independent in structure: the number of options at each stage must not depend on the specific choices made earlier, only (at most) on how many items are used up.

Steps1Break the task into stages(choices made one at a time)2Count the options at each stage3Adjust for restrictions such as no repeats4Multiply the counts togetherChoose the most restrictive stage first when constraints appear
The principle turns a big counting problem into a product of small ones. Writing a blank for each stage helps.

Repeats allowed vs not allowed

If repeats are allowed, every stage has the same number of options: a 4-digit PIN with repeats gives 10410^4 codes. If repeats are not allowed, each stage has one fewer option than the last: 10⋅9⋅8⋅710\cdot9\cdot8\cdot7. That second product is a permutation.

Handling constraints

When a position has a restriction (for example, the first digit cannot be 0), fill the restricted position first, then the others. Starting with the free positions can leave you unsure how many options the restricted one has.

Worked example

A license plate has 3 letters followed by 3 digits. How many plates are possible if repeats are allowed? If no letter or digit may repeat?

Repeats allowed: 263⋅103=17,576×1000=17,576,00026^3\cdot10^3=17{,}576\times1000=17{,}576{,}000.

No repeats: 26⋅25⋅24⋅10⋅9⋅8=15,600⋅720=11,232,00026\cdot25\cdot24\cdot10\cdot9\cdot8=15{,}600\cdot720=11{,}232{,}000.

Try it yourself

How many 4-digit PINs have no repeated digit?

Show the answer

10⋅9⋅8⋅7=504010\cdot9\cdot8\cdot7=5040. Each digit rules out the one already used.

Keep going with practice

Counting techniques are the base of Vidi's probability lessons, leading to permutations, combinations and binomial probabilities.