Answer
$xy'=-sin x -y$ and $0$
Work Step by Step
Need to use quotient rule of differentiation.
Thus, $y'=\dfrac{-x \sin x -\cos x}{x^2}=(\dfrac{-\sin x}{x}) -(\dfrac{1}{x})\dfrac{\cos x}{x}$
As we are given that $y=\dfrac{\cos x}{x}$
Thus, $y'=(\dfrac{-\sin x}{x}) -\dfrac{y}{x}$
and, $xy'=-sin x -y$
Now, apply the initial conditions.
$y(\dfrac{\pi}{2})=\dfrac{\cos \dfrac{\pi}{2}}{\dfrac{\pi}{2}}=0$