It's not hard to simply count through them manually. The following numbers between one and one thousand begin with the digit 1:
That gives us a tally of 1 + 10 + 100 + 1, which equals 112.
More interestingly though, we can see a pattern in how those numbers add up. For example, what if the question was:
"How many numbers between 1 and 1030 begin with the digit 1?"
The answer would be:
111111111111111111111111111112
In other words, for any number that is a power of ten, the quantity of integers between one and that number (inclusive), would be as many digits as the power, and all of those digits would have a value of 1, except the last one, which would be 2.
Or more technically, if x = 10n, then:
nd = 1 + Σ 10n
1
Where d is the number of values from 1 to x that have 1 as the first digit.
Chat with our AI personalities
1000
Zero
555
90 of them.
Specify whether you are including the numbers between 0000 and 1000.