Find the absolute maximum and minimum values of the function f given by f (x) = cos^2 x + sin x, x ∈ [0, π]