Number of non-equivalent five-digit numbers

197 Views Asked by At

Suppose that any two $n$-digit numbers are considered equivalent if it contains the same digits, but in a different order (eg. 34068, 03468 and 86304 are equivalent)

How many five-digit numbers are not equivalent (leading digits allowed)?

Given solution:

2002

My solution:

Any of the 10 digits can be in the first place, any 9 of the remaining digits can be in the second place...

Therefore, $\frac{10!}{5!} = 10\times9\times8\times7\times6 = 30240$ non-equivalent five-digit numbers exist

Where is my reasoning wrong (or is the given solution wrong)?
2002 seems like a small number

1

There are 1 best solutions below

0
On BEST ANSWER

Consider cases: Since strings in which the same digits appear the same number of times are equivalent, what matters is which digits are used and how often each digit appears in the five-digit string.

  1. The string contains five different digits: Each digit appears once in the string. There are $$\binom{10}{5}$$ ways to select the digits.
  2. The string contains four different digits: One digit appears twice and each of the others appears once. There are $10$ ways to select the digit that appears twice and $\binom{9}{3}$ ways to select which three of the remaining digits appear once. Hence, there are $$10\binom{9}{3}$$ such cases.
  3. The string contains three different digits: Either one digit appears three times and each of the others appears once or two digits appear twice and one digit appears once.

For the first case, there are $10$ ways to pick the digit that appears three times and $\binom{9}{2}$ ways to pick the digits that appear once. For the second case, there are $10$ ways to pick the digit that appears once and $\binom{9}{2}$ ways to pick the digits that appear twice. Hence, there are $$10\binom{9}{2} + 10\binom{9}{2}$$ such cases.

  1. The string contains two different digits: Either one digit appears four times and the other appears once or one digit appears three times and the other appears twice.

In each of the two cases, there are $10$ ways to pick the number that appears more often in the string and $9$ ways to pick the remaining digit. Hence, there are $$10 \cdot 9 + 10 \cdot 9$$ such cases.

  1. The string contains one (repeated) digit: There are $10$ ways to choose the digit that occupies each position of the string.

Since the cases are mutually exclusive and exhaustive, the answer can be found by adding the results for the above cases.