<s>[INST] Problem based on Range Find $a$ and $b$ such that the inequality $a \le 3 \cos{x} + 5\cos\left(x - \frac{\pi}{6}\right) \le b$ holds good for all x.
 [/INST] We can take for example $a=-100$ and $b=100$.  However, it might be interesting to find sharp bounds $a$ and $b$. That is a standard max/min problem. We will solve the problem without using the calculus. 
Note that 
$$\cos(x-\pi/6)=\cos x\cos(\pi/6)+\sin x\sin(\pi/6)=(\cos x)(\sqrt{3}/2)+(\sin x)(1/2).$$
Thus 
$$3\cos x+5\cos(x-\pi/6)=\frac{6+5\sqrt{3}}{2}\cos x +\frac{5}{2}\sin x.$$
To make the structure clearer (and make typing easier), let $p=\frac{6+5\sqrt{3}}{2}$ and $q=\frac{5}{2}$.
Note that 
$$(p\cos x+q\sin x)^2+(p\sin x-q\cos x)^2=p^2+q^2.$$
Thus $(p\cos x+q\sin x)^2$ can never be bigger than $p^2+q^2$, and is equal to $p^2+q^2$ precisely if $p\sin x -q\cos x=0$, that is, if $\tan x=q/p$. 
In the first quadrant, $\tan x=q/p$  at roughly $0.33$ radians.  At that value of $x$, the numbers $\cos x$ and $\sin x$  are positive, so our function is maximized.
There is also a solution of $\tan x=q/p$ in the third quadrant, where $\cos x$ and $\sin x$ are both negative, so our function is minimized. Thus
$$-\sqrt{p^2+q^2} \le 3\cos x +5\cos(x-\pi/6) \le \sqrt{p^2+q^2},$$
and these bounds are best possible.
Comment: One can obtain the same result more mechanically by using the calculus.  The derivative of $p\cos x+q\sin x$ is $-p\sin x+q\cos x$. This derivative is $0$ when $\tan x=q/p$. 
Another way of looking at things is to rewrite our expression as 
$$\sqrt{p^2+q^2} \left(\frac{p}{\sqrt{p^2+q^2}}\cos x+\frac{q}{\sqrt{p^2+q^2}}\sin  x\right).$$
Let $\theta$ be the angle whose sine is $p/\sqrt{p^2+q^2}$ and whose cosine is $q/\sqrt{p^2+q^2}$.
Then our expression is equal to
$$\sqrt{p^2+q^2} \sin(x+\theta),$$
and sharp bounds follow easily.
</s>