Official Solution:How many times will the digit 7 be written when listing the integers from 1 to 1000?A. 110
B. 111
C. 271
D. 300
E. 304
Many approaches are possible. For example:
Approach #1: Consider numbers from 0 to 999 written as follows:
1. 000
2. 001
3. 002
4. 003
...
1000. 999
We have 1000 numbers. We used 3 digits per number, hence used total of \(3*1000=3000\) digits. Now, why should ANY digit have preferences over another? We used each of 10 digits equal # of times, thus we used each digit (including 7) \(\frac{3000}{10}=300\) times.
Approach #2: There are several ways to count the number of times 7 appears between 7 and 997. One way is to consider the number of 7's in single, double, and triple digit numbers separately.
One-digit numbers: 7 is the only one-digit number.
Two-digit numbers: 7 could be the tens digit or the units digit. Case 1: 7 is the tens digit. There are 10 ways to place 7 as the tens digit of a two-digit number. Case 2: There are 9 ways to place the units digit. Thus, for two-digit numbers we have: \(10+9=19\) numbers that contain a 7.
Three-digit numbers: Use the knowledge from the previous two scenarios: each hundred numbers will contain one 7 in numbers such as 107 or 507 and also 19 other sevens in numbers such as 271 or 237. Thus a total of 20 sevens per each hundred and 200 sevens for 1000. Since we have 700's within the range, that adds another 100 times that a seven will be written for a total of 300 times.
Approach #3: In the range 0-100:
7 as units digit - 10 times (7, 17, 27, ..., 97);
7 as tens digit - 10 time (71, 72, 73, ..., 79);
So in first one hundred numbers 7 is written \(10+10=20\) times.
In 10 hundreds 7 as units or tens digit will be written \(10*20=200\) times. Plus 100 times when 7 is written as hundreds digit (700, 701, 702, ..., 799).
Total \(200+100=300\).
Answer: D
_________________