Answer
Diverges
Work Step by Step
We need to use formula: $\int_a^{+\infty} f(x) dx=\lim\limits_{M \to +\infty}\int_a^{M} f(x) \ dx$
Therefore, $\lim\limits_{M \to +\infty}\int_0^{M} \cos x dx=\lim\limits_{M \to +\infty}[\sin x ]_0^{M}$
Now, we will evaluate the limits .
$\lim\limits_{M \to +\infty}[\sin x ]_0^{M}=\lim\limits_{M \to +\infty}[\sin M-\sin 0 ]=\lim\limits_{M \to +\infty} (\sin M)\\=\sin (\infty)$
We conclude that the limit does not exist. So, the improper integral diverges.