SOLUTION : $\text { Let } y=\cot ^{-1}\left(\sqrt{1+x^2}-x\right) \\$
$\text { Let } x=\tan \theta \Rightarrow \theta=\tan ^{-1} x \\$
$y=\cot ^{-1}\left(\sqrt{1+\tan ^2 \theta}-\tan \theta\right) \quad \Rightarrow \quad y=\cot ^{-1}(\sec \theta-\tan \theta) \\$
$y=\cot ^{-1}\left(\frac{1}{\cos \theta}-\frac{\sin \theta}{\cos \theta}\right) \Rightarrow y=\cot ^{-1}\left(\frac{1-\sin \theta}{\cos \theta}\right) \\$
$y=\cot ^{-1}\left[\frac{1-\cos \left(\frac{\pi}{2}-\theta\right)}{\sin \left(\frac{\pi}{2}-\theta\right)}\right]$
$\Rightarrow y=\cot ^{-1}\left(\frac{2 \sin ^2\left(\frac{\pi}{4}-\frac{\theta}{2}\right)}{2 \sin \left(\frac{\pi}${4}-$\frac{\theta}{2}\right) \cos \left(\frac{\pi}{4}-\frac{\theta}{2}\right)}\right] \quad \Rightarrow \quad y=\cot ^{-1}\cot \left(\frac{\pi}{2}-\frac{\pi}{4}+\frac{\theta}{2}\right) \\$
$y=\cot ^{-1} \tan \left(\frac{\pi}{4}-\frac{\theta}{2}\right) \\$
$\therefore \quad y=\frac{\pi}{4}+\frac{1}{2} \tan ^{-1} x$
$\quad \Rightarrow \quad y=\frac{\pi}{4}+\frac{\theta}{2}$