Find the following limit $$L=\lim_{x\to 1}\left(2-x\right)^{\tan\frac{\pi x}{2}}.$$ Without L'Hopital's rule!
My try: $$L=\lim_{x\to1} e^{\ln \left[(2-x)^{\tan\frac{\pi x}{2}}\right]}=\lim_{x\to 1} e^{\tan\frac{\pi x}{2}\ln(2-x)}$$ Now we want to find $$\lim_{x\to1} \tan\frac{\pi x}{2}\ln(2-x)=\ln1\lim_{x\to1}\tan \dfrac{\pi x}{2}$$ I am stuck here.
$$\lim_{x\to1}\log (2-x)\tan \dfrac{\pi x}{2} $$ Let $t=1-x$, as $x\to 1$, $t\to 0$ and your limit becomes: $$\lim_{t\to 0} \log(1+t)\tan \left(\frac{\pi}2(1-t)\right)=\lim_{t\to0}\log(1+t)\cot (\pi t/2)$$ Now, recall that $\log(1+t)\sim t$ and $\cot (\pi t/2)\sim 2/(\pi t)$: $$\log(1+t)\cot (\pi t/2)\to \frac2{\pi}\ \quad \text{as}\quad t\to 0$$