\(\left(\sqrt{7-x}\right)^2=\left(x-1\right)^2\)
=> 7-x=x2-2x+1
=> x2-2x+1+x-7=0
=> x2-x-6=0
=> x2-3x+2x-6=0
=> (x-3)(x+2)=0
=> \(\left[{}\begin{matrix}x-3=0\\x+2=0\end{matrix}\right.\)
=> \(\left[{}\begin{matrix}x=3\left(TM\right)\\x=-2\left(KTM\right)\end{matrix}\right.\)