we need to make a number code with 4 digits. how many codes have at least two equal digits? and how many codes have exactly 3 equal digits?

Respuesta :

Answer:

First do the case in which none of the digits is 0.

There are 9 ways to choose the digit that repeats 3 times and 8 ways to pick the other, after this there are 4 ways to order the digits. So 9×8×4.

Now we look at the cases in which the digit 0 repeats 3 times. Clearly the 9 numbers are 1000,2000,3000,…,9000.

Lastly we look at the cases in which 0 appears once. There are 9 ways to pick the other digit and 3 ways to order.

So the final answer is 9×8×4+9+9×3.

RELAXING NOICE
Relax