Michael writes down all the integers between 1 and inclusive on a piece of paper and discovers that exactly of them have leftmost digit 1 . Given that , find the smallest possible value of .
Solution
Let be the number of digits of . Suppose that does not itself have leftmost digit 1 . Then the number of integers which have leftmost digit 1 is so we must have , or . But the left-hand side is odd, so this is impossible. Thus must have leftmost digit 1 . In this case, the number of integers which have leftmost digit 1 is Therefore we need , or . Then, must be divisible by 3. The base-ten representation of has ones, so must be divisible by 3 . Both and make less than 2017, but gives the answer .
Want a route through all this instead of an archive? The track
puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.