The numbers $2^{1989}$ and $5^{1989}$ are written out one after the other (in decimal notation). How many digits are written altogether?

Let's think step by step and output the final answer within \boxed{}.
user