Step 1: Plan:
We remove the square root by writing $x=z^2$ with $z\ge 0$. Then $dx=2z\,dz$ and $\cos\sqrt{x}=\cos z$, so the problem is $2\int z\cos z\,dz$.
Step 2: Use the LIATE-style choice:
For $\int z\cos z\,dz$, the algebraic part $z$ is chosen as the first function and $\cos z$ as the second. The by-parts rule is $\int f g\,dz = f\int g\,dz - \int\left(f'\int g\,dz\right)dz$.
Here $f=z$, $g=\cos z$, so $\int g\,dz=\sin z$ and $f'=1$.
Step 3: Work it out:
\[ \int z\cos z\,dz = z\sin z - \int \sin z\,dz = z\sin z + \cos z \]
So
\[ \int\cos\sqrt{x}\,dx = 2z\sin z + 2\cos z + k \]
Putting $z=\sqrt{x}$ back gives $2\sqrt{x}\sin\sqrt{x}+2\cos\sqrt{x}+k$.
Step 4: Match with the options:
The expression equals $2\left(\sqrt{x}\sin\sqrt{x}+\cos\sqrt{x}\right)+k$, which is option (C).
Option (A) and option (D) have no factor $\sqrt{x}$ multiplying the sine, so they cannot match. Option (B) has the coefficient $\frac{1}{2}$ and a minus sign, and differentiating it does not return $\cos\sqrt{x}$.
Final Answer:
The integral equals $2(\sqrt{x}\sin\sqrt{x}+\cos\sqrt{x})+k$, option (C).
\[ \boxed{2\left(\sqrt{x}\sin\sqrt{x}+\cos\sqrt{x}\right)+k} \]