How to find the maximum and minimum value of y = cos2x + SiNx, y = 1-2 (the square of SiNx) + SiNx = 2 (the square of sinx-1 / 4) + 9 / 8

How to find the maximum and minimum value of y = cos2x + SiNx, y = 1-2 (the square of SiNx) + SiNx = 2 (the square of sinx-1 / 4) + 9 / 8

Function y = cos2x + SiNx
=1-2 (sin ^ 2 x) + SiNx (cosine of double angle)
=-2 (sinx-1 / 4) ^ 2 + 9 / 8 (matching method)
sinx=1/4
y max=9/8
sinx=-1
y min=-2