I've done this in two different ways.
First: $$\int _0 ^{2 \pi} \sin x \cos x dx = 2 \int _0 ^\pi \sin x \cos x dx = 0,$$ since $\cos(\pi - x) = - \cos x$.
By using the property $$\int _0 ^{2a} f(x) dx = 0 \text{ if } f(2a-x)=-f(x)$$ or $$\int _0 ^{2a} f(x) = 2 \int _0 ^a f(x) dx \text{ if } f(2a-x)=f(x).$$
Second way:
$$\begin{align*}\int _0 ^{2\pi} \sin x\cos x dx &= \frac 1 2 \times \int _0 ^{2\pi} \sin(2x) dx\\ &= \int _0 ^\pi \sin(2x) dx. \\& \boxed{\text{Since $\sin(2(2π-x)) = \sin(2x)$},} \\ &= 2 \times \int _0 ^{\pi \over 2} \sin(2x) dx\\ &= 4 \times \int _0 ^{\pi \over 4} \sin(2x) dx, \end{align*}$$ since $$ \sin\left(2\left[\frac \pi 2 - x\right]\right) = \sin(\pi-2x) = \sin(2x), $$ which upon integrating I get answer as $2$.
I didn't understand where my approach is wrong so which answer I must assure.
The mistake is in the step:
$$\int_{0}^{\pi} \sin(2x) dx = 2\cdot\int_{0}^{\pi / 2} \sin(2x) dx$$
where you provide (or seek to) the reasoning that $\sin(2(\pi-x))=\sin(x)$. But this is not true because $\sin(2(\pi-x))=-\sin(x)$.
Which indeed shows that $\int_{0}^{\pi} \sin(2x) dx$ is odd about $\pi / 2$ giving the value of original integral as $0$.