Answer
$x=\frac{\pi}{4}$ is the critical point of $f$.
The maximum value is $\sqrt 2$ and the minimum value is 1.
Work Step by Step
$f'(x)=\cos x-\sin x$
$f'(x)$ exists for all $x$.
$f'(x)=\cos x-\sin x=0\implies$
$ \cos x=\sin x\implies x=\frac{\pi}{4}$
$x=\frac{\pi}{4}$ is the critical point of $f$.
We compare the values of the function at the critical points and at the end points to find the maximum and minimum values.
$f(\frac{\pi}{4})=\sin\frac{\pi}{4}+\cos \frac{\pi}{4}=\sqrt 2$
$f(\frac{\pi}{2})=\sin\frac{\pi}{2}+\cos\frac{\pi}{2}=1$
$f(0)=\sin 0+\cos0=1$
The maximum value is $\sqrt 2$ and the minimum value is 1.