\(sinx-cos\left(\pi-x\right)=-\frac{1}{2}\)
\(\Leftrightarrow sinx+cosx=-\frac{1}{2}\)
\(\Rightarrow\left(sinx+cosx\right)^2=\frac{1}{4}\)
\(\Rightarrow sin^2x+cos^2x+2sinx.cosx=\frac{1}{4}\)
\(\Rightarrow1+2sinx.cosx=\frac{1}{4}\Rightarrow sinx.cosx=-\frac{3}{8}\)
\(T=\frac{1}{sinx}+\frac{1}{cosx}=\frac{sinx+cosx}{sinx.cosx}=\frac{-\frac{1}{4}}{-\frac{3}{8}}=\frac{2}{3}\)