Find $\int_{0}^{\frac{\pi}{2}} \frac{1}{1+\tan(x)^{\sqrt{2}}}dx$. 
Find $\displaystyle \int_{0}^{\dfrac{\pi}{2}} \dfrac{1}{1+\tan(x)^{\sqrt{2}}}dx$.

I am told I should solve this by switching the limits, but I am unsure of the substitution I should use.
 A: You may observe that, by the change of variable $x \to \pi/2-x$, you get
$$I=\int_{0}^{\dfrac{\pi}{2}} \dfrac{1}{1+\tan(x)^{\sqrt{2}}}dx=\int_{0}^{\dfrac{\pi}{2}} \dfrac{1}{1+\frac1{\tan(x)^{\sqrt{2}}}}dx=\int_{0}^{\dfrac{\pi}{2}} \dfrac{\tan(x)^{\sqrt{2}}}{1+\tan(x)^{\sqrt{2}}}dx
$$ giving
$$
2I=I+I=\int_{0}^{\dfrac{\pi}{2}} \dfrac{1}{1+\tan(x)^{\sqrt{2}}}dx+\int_{0}^{\dfrac{\pi}{2}} \dfrac{\tan(x)^{\sqrt{2}}}{1+\tan(x)^{\sqrt{2}}}dx=\int_{0}^{\dfrac{\pi}{2}} dx=\frac{\pi}{2} 
$$
 or
$$
I=\color{blue}{\frac{\pi}4}. 
$$
A: Let $I(\alpha)$ be given by
$$I(\alpha)=\int_0^{\pi/2}\frac{1}{1+\tan^{\alpha}x}\,dx \tag 1$$
Then, let $x \mapsto \pi/2-x$ so that $\tan (\pi/2 -x)\mapsto \cot x$, $dx \mapsto  -dx$, and the limits of integration go from $\pi/2$ to $0$.  Then we have
$$I(\alpha) = \int_0^{\pi/2}\frac{\tan^{\alpha }x}{1+\tan^{\alpha }x}\,dx \tag 2$$
Adding $(1)$ and $(2)$ and dividing by two reveals that 
$$I(\alpha)=\frac12\int_0^{\pi/2} \frac{1+\tan^{\alpha}x}{1+\tan^{\alpha}x}\,dx=\frac{\pi}{4}$$
which is independent of $\alpha$! 
