Let $S$ represent the set of all natural numbers : 9,999 $<$ x < 100,000.
Let $A_i$ represent the set of all numbers in $S$ where no digit in $x$ equals $i$. $\\$
For example, $98,766 \in A_i$ but $11,001 \notin A_i$.
(a) $|A_0 | \cup |A_1| \cup |A_2|$
(b) $\overline{ |A_0 | \cup |A_1| \cup |A_2|} $
My solution:
We know that there are a total of 99,999-10,000 = 89,000 numbers in set $S$. And we know all numbers in $S$ are 6-digits long. So I think $|A_0|$ = $9^6$ , but for $|A_1|$ and $|A_2|= 8*9^5$ because the first digit cannot start with a 0 since the number has to be between the range above.
My problem then becomes how I should count the duplicates. I know ultimately I should use the inclusion exclusion principle to figure out this answer, but I am stuck in figuring out the intersections. Can anyone help me? Thanks in advance!
For a direct route, you can just consider that each digit can be one of $(3,4,5,6,7,8,9)$ and infer that the count of such $5$-digit numbers, given $7$ choices for each location, is $7^5 = 16807$
If the revised range is inclusive - that is, $9999$ is also included in the range - then obviously there is $1$ more to add.