An access control system uses a PIN code consisting of 4 digits (0-9). I was able to learn that the correct PIN includes the digits 2, 4, and 7 at least once each, with my super spy tricks. Only 2, 4 and 7 appear to have been pressed. I would like to know how many possible PINs match this constraint. How many 5-digit PINs are there where 2, 4, and 7 appear at least once each?
So I am assuming that it is a simple solution based on the book, $10^5 -10^3=99,000$
Is my approach correct?
The cases where one of those digits is missed are cases of five digits and nine options each so it's:$9^5$. The whole options of PIN code are $10^5$.
So the amount of options with those digits is:$10^5-3\times 9^5$
Because we're doing this for every digit