<s>[INST] Differentiation using l´Hopital I need to use L´Hopital's rule with this functions:
$$\lim_{x\rightarrow\frac{\pi}{2}} (1-\sin(x))^{\cos(x)}$$
$$\lim_{x\rightarrow\frac{\pi}{4}} (\tan(x))^{\tan(2x)}$$
I take the exponent down using the properties of logarithms and then make the denominator like: $\lim_{x\rightarrow\frac{\pi}{2}} \frac{\cos(x)}{\frac{1}{\ln(1-\sin(x))}}$ but I still get stuck.
 [/INST] Here is my take on the second and a remark on the first limit:
$\lim_{x\rightarrow\frac{\pi}{4}} (\tan(x))^{\tan(2x)}$: 
So, consider 
\begin{eqnarray*} \tan(2x)\ln(\tan x)
& \stackrel{\tan(2x)= \frac{2\tan x}{1-\tan^2x}}{=} & 2\frac{\tan x\cdot \ln(\tan x)}{1-\tan^2x}\\
& \stackrel{t = \tan x, t\to1}{=} & 2\frac{t \ln t}{1-t^2} \\
& \stackrel{L'Hosp.}{\sim} & 2\frac{\ln t + 1}{-2t}\\
& \stackrel{t\to 1}{\longrightarrow} & -1
\end{eqnarray*}
Hence, $\boxed{\lim_{x\rightarrow\frac{\pi}{4}} (\tan(x))^{\tan(2x)} = e^{-1}}$.
$\lim_{x\rightarrow\frac{\pi}{2}} (1-\sin(x))^{\cos(x)}$:
I recommend just to consider the logarithmic limit and not to write all time $e^{\lim ...}$. This is tedious and not necessary:
\begin{eqnarray*} \cos x \ln(1-\sin x)
& = & \frac{\ln(1-\sin x)}{\frac{1}{\cos x}}\\
& \stackrel{L'Hosp.}{\sim} & -\frac{\frac{\cos}{1- \sin x}}{-\frac{\sin x}{\cos^2 x}}\\
& = & \frac{\cos^3 x}{\sin x (1-\sin x)} \\
& = & \frac{\cos x (1-\sin^2 x)}{\sin x (1-\sin x)} \\
& \stackrel{\frac{1-\sin^2 x}{1-\sin x} = 1+\sin x}{=} & \frac{\cos x (1+\sin x)}{\sin x}\\
& \stackrel{x\to \frac{\pi}{2}}{\longrightarrow} & 0
\end{eqnarray*}
Hence, $\boxed{\lim_{x\rightarrow\frac{\pi}{2}} (1-\sin(x))^{\cos(x)} = e^0 = 1}$.
</s>