TITLE: Probability that the first digit of $2^{n}$ is 1
QUESTION [11 upvotes]: Let $a_{n}$ be the number of terms in the sequence $2^{1},2^{2},\cdots ,2^{n}$ which begins with digit 1.
Prove that $$\log2 -\frac{1}{n}<\frac{a_{n}}{n}<\log2\text{  (log base is 10)}$$

Note: This is only a part of the question.The actual question is:Prove that the probability that randomly chosen power of 2 begins with 1 is $\log2$.
The rest is quite easy(once I've proven the above inequality).Could anyone give me any hint for solving this question?Thanks!

REPLY [11 votes]: Hint 1: Show that there is always a power of 2 that has $k$ digits and starts with 1. (For $k=1$, I'm including $2^0=1$.) Use Shreevastsa's hint about logarithms.
Hint 2: Show that there is at most 1 power of 2 that has $k$ digits and starts with 1.
Hence, there are exactly $k$ powers of 2 from 1 to $2 \times 10^k$ that start with 1.
For any $n$, $2^n$ has $ \lfloor n \log 2 \rfloor + 1$ digits, hence $a_n = \lfloor n \log 2 \rfloor$, so $a_n < n \log 2$, which gives us the RHS.
For the LHS, show that $\lceil n \log 2 \rceil - 1 = a_n $.