If $a^b$ has $b$ digits, what is the greatest value of $b$? 
For natural numbers $a$ and $b$, what is the greatest value of $b$ so that $a^b$ has $b$ digits?

I knew that the greatest value of $b$ is $21$, where $9^{21}=\underset{21 \text{ digits}}{\underbrace{109,418,989,131,512,359,209}}$, but I am not sure how to prove that there is no greater value of $b$.

If $a^b$ has $b$ digits then 
$10^{b-1} \le a^b < 10^b$.
$\log 10^{b-1} \le \log a^b < \log 10^b$ (Notation: $\log$ means $\log_{10}$)
$b-1 \le b\log a < b$
$1 - \frac 1b \le \log a <1$.  so $a < 10$
The largest we can allow $b$ to be, the closer to $1$ that $\log a$ will be. 
Smaller values of $a$ will result is smaller options for $b$ and large options of $a$ will allow for larger options for $b$.  And if $a <a'$ and $b < b'$ we have $a^b < a'^{b'}$ we clearly will get larger values of $a^b$ if $a$ is as large as possible.  So we can make $b$ largest (and therefore $a^b$ largest) when $a = 9$.
so $1-\frac 1b \le \log 9< 1$
which means $b \le \frac 1{1-\log 9}$
Welp.... calculator time... $b \le 21.85$ so $9^{21}$ is indeed the largest such number.
