Okay so I'm doing combinatorics and I have the following question:
Between 1000 and 9999, how many numbers contain "3" only once? (So the number 3 has to be only once in the whole number). The answer is 2673.
I can't come to the right answer cause how I would proceed is like this:
1 9 9 9 --> since I can have 3 only once I would do 9^3 times 4.
Probably the only trap is that numbers don't start with 0.
If the 3 is in the first place...
If the 3 is any other place...
In total: $729+3 \times 648=2673$.