$y^2=(2016^2+2017^2)(\sin^2x+\cos^2x)-(2016\cos x-2017\sin x )^2 \le (2016^2+2017^2)(\sin^2x+\cos^2x)=2016^2+2017^2$$\Rightarrow -\sqrt{2016^2+2017^2} \le y \le \sqrt{2016^2+2017^2}$
$ y_{\min}=-\sqrt{2016^2+2017^2}$ chẳng hạn khi $x= \pi+\arctan \frac{2016}{2017}$
$y_{\max}=\sqrt{2016^2+2017^2}$ chẳng hạn khi $x=\arctan \frac{2016}{2017}$