What's the correct notation for log squared?

Solution 1:

Most people will use $\log^2(n)$ and there is no problem with that. If you want to be absolutely certain no one will think you are talking about $\log\log n$, then you can write $\bigl(\log(n)\bigr)^2$