TITLE: What is the behaviour of the first $n$ digits of ${\underbrace{99\dots99}_{n\text{ nines}}}^{\overbrace{99\dots99}^{n\text{ nines}}}$ as $n\to\infty$
QUESTION [7 upvotes]: For a natural number $n$, let $f(n)$ denote the first $n$ digits of the decimal expansion of $${\underbrace{99\dots99}_{n\text{ nines}}}^{\overbrace{99\dots99}^{n\text{ nines}}}=(10^n-1)^{10^n-1}.$$ So we have $10^{n-1}\le f(n)<10^n$. Then what can we say about $\lim_{n\to\infty} \frac{f(n)}{10^n}$ ?

For simplicity, let $y_n=(10^n-1)^{10^n-1}$. Then we have $$y_n=10^{\log_{10}(y_n)}=\underbrace{10^{\lfloor \log_{10}(y_n)\rfloor}}_{\text{integer}}\cdot 10^{\{ \log_{10}(y_n)\}},$$
where $\lfloor\cdot\rfloor$ denotes flooring and $\{\cdot\}$ denotes the fractional part.
So the first $n$ digits of $y_n$ are given by $$f(n)=10^{n-1}\cdot 10^{\{ \log_{10}(y_n)\}}.$$
Using this (somewhat) closed form, I can do numerical experiments in Mathematica, which suggest that $\lim_{n\to\infty}\frac{f(n)}{10^n}=\frac1e$:


Indeed, it would be enough to understand the bevahiour of $\{ \log_{10}(y_n)\}$ as $n\to\infty$.

REPLY [2 votes]: (Short version of Maximilian Janisch's answer)
We have
$$x_n:=\bigl(10^n-1)^{10^n -1}=\bigl(10^n)^{10^n -1}\>z_n$$
with
$$z_n:=\bigl(1- 10^{-n}\bigl)^{10^n}\cdot\bigl(1-10^{-n}\bigr)^{-1}\ \to\ {1\over e}\cdot 1\qquad(n\to\infty)\ .$$
As $x_n$ and $z_n$ have the same first digits in base $10$ it follows that in the limit the first digits of $x_n$ are the first digits of ${1\over e}$, namely $367879\ldots \ $.