\(M=sinx.cosx+\dfrac{sin^2x}{1+cotx}+\dfrac{cos^2x}{1+tanx}\)
\(=sinx.cosx+\dfrac{sin^2x}{\dfrac{cosx+sinx}{sinx}}+\dfrac{cos^2x}{\dfrac{cosx+sinx}{cosx}}\)
\(=sinx.cosx+\dfrac{sin^3x+cos^3x}{cosx+sinx}\)
\(=sinx.cosx+\dfrac{\left(sinx+cosx\right)\left(sin^2x+cos^2x-sinx.cosx\right)}{cosx+sinx}\)
\(=sinx.cosx+sin^2x+cos^2x-sinx.cosx\)
\(=sin^2x+cos^2x=1\)