How to approach $\displaystyle\lim_{x\to0} (\cos x)^{\frac{1}{x^2}}$ I'm working through some apparently tricky limits (for a basic fellow like me), and I'm not sure how to treat the following situation:
$$\displaystyle\lim_{x\to0} (\cos x)^{\frac{1}{x^2}}$$
How does one deal with powers which include $x$ when evaluating limits? I'm not after an exact evaluation of the limit. I'm just interested in how to go about it so that I can reach the answer Wolfram spits out as $$\frac{1}{\sqrt{e}}$$
Thanks for your patience and time, all.

Setting $x=2h$ $$\lim_{h\to0}(1-2\sin^2h)^{\frac1{4h^2}}=\left(\lim_{h\to0}\left[1+(-2\sin^2h)\right]^{-2\sin^2h}\right)^{-\frac12\left(\lim_{h\to0}\frac{\sin h}h\right)^2}$$
The inner limit converges to $e$
