\(P=\frac{2\left(\sqrt{x}+3\right)-5}{\sqrt{x}+3}=2-\frac{5}{\sqrt{x}+3}\)
Để P thuộc Z thì \(\left(\sqrt{x}+3\right)\inƯ\left(5\right)=\left\{-1;1;-5;5\right\}\)
\(\Leftrightarrow\left[{}\begin{matrix}\sqrt{x}+3=-1\\\sqrt{x}+3=1\\\sqrt{x}+3=5\\\sqrt{x}+3=-5\end{matrix}\right.\Leftrightarrow\left[{}\begin{matrix}\sqrt{x}=-4\left(vl\right)\\\sqrt{x}=-2\left(vl\right)\\\sqrt{x}=2\\\sqrt{x}=-8\left(vl\right)\end{matrix}\right.\)
vậy x=4 thì P thuộc Z