Task A-3.8. (10 points)

Determine the smallest natural number $N$ greater than 1000 such that exactly half of the numbers from 1 to $N$ have at least one digit 1 in their decimal representation.
## First solution.

First, let's determine how many numbers do not contain the digit 1 among the numbers from 1 to 999. Such numbers are written using the digits $0, 2, 3, \ldots, 9$. There are 8 single-digit numbers, 72 two-digit numbers ($8 \cdot 9 = 72$),

1 point

and 648 three-digit numbers ($8 \cdot 9 \cdot 9 = 648$). In total, there are $9^3 - 1$, which is 728. 2 points

All numbers between 1000 and 1999 contain the digit 1, so for $N, 1000 \leqslant N < 2000$, among the numbers from 1 to $N$, there are 728 numbers that do not have the digit 1 in their decimal representation.

From the condition $728 = \frac{1}{2} N$

1 point

it follows that $N = 1456$.

3 points

1 point

2 points