2^x = x^2 take the log of each side
log 2^x = log x^2 and we can write
x log 2 = 2 log x
Rearrange as
x / log x = 2 / log 2
And it must be that x = 2
Apparently 4 is a possible solution as well, according to WolframAlpha. However, I have no idea how to solve it.