been trying to this for some time now dont get it lol :S

$\displaystyle (tan(x))^x$

i tried chain rule :s

let y=u^x and u=tan(x)

y'=ln(u)/u , u'=sec^2(x)

$\displaystyle \frac{dy}{dx}=\frac{sec^2(x).ln|tan(x)|}{tan(x)}$

but ans is $\displaystyle [ln|tan(x)|+2xcosec(2x)](tan(x))^x$