$\begin{align*}&f(x) = x^2 \\
&g(x) = x\sin x + \cos x \end{align*}$
We are asked to make this two function equal and see at how many points they meet.
$\Rightarrow f(x) = g(x)$
$\Rightarrow x^2 = x \sin x + \cos x$
$\Rightarrow {\color{blue}{x^2 -x\sin x - \cos x}} = 0$
$\Rightarrow F(x) = 0$
This $F(x)$ is even and we just need to check at how many points $F(x)$ crosses the $X$ - axis for $x > 0$.
$F(0)$ = $-1$
$F^{'}(x) = 2x - x \cos x$
$F^{'}(x) = x\left ( {\color{red}{2 - \cos x}} \right )$
Here ${\color{red}{2 - \cos x}}$ is greater than $0$ and $x\left ( {\color{red}{2 - \cos x}} \right )$ will be also greater than $0$ for $x > 0$.
$\Rightarrow F(x){\color{red}{ \text{ is strictly increasing function.}}}$
Therefore $F(x)$ will cut at only one point for $x > 0$.
As we have already seen that $F(x)$ is even, therefore $F(x)$ has only two real roots.
Correct Answer: $C$