.
This problem is solved in 3 steps.
Step 1.
How many are there 5 digit counting numbers in all ?
The answer is 9*10*10*10*10 = 90000, because such a number can have
- any of 9 digits from 1 to 9 in the mostleft position;
- any of 10 digits from 0 to 9 in the 2nd position;
- any of 10 digits from 0 to 9 in the 3rd position;
- any of 10 digits from 0 to 9 in the 4th position;
- any of 10 digits from 0 to 9 in the 5th position.
In all, there are 90000 such numbers.
Step 2.
How many are there 5 digit counting numbers that HAVE NO the digit 6 ?
The answer is 8*9*9*9*9 = 52488, because such a number can have
- any of 8 digits from 1 to 9 except of 6 in the mostleft position;
- any of 9 digits from 0 to 9 except of 6 in the 2nd position;
- any of 9 digits from 0 to 9 except of 6 in the 3rd position;
- any of 9 digits from 0 to 9 except of 6 in the 4th position;
- any of 9 digits from 0 to 9 except of 6 in the 5th position.
Step 3.
Now the number under the problem's question is the difference 90000 - 52488 = 37512.