\(A=\dfrac{x-2}{x+3}=\dfrac{x+3-5}{x+3}=\dfrac{x+3}{x+3}-\dfrac{5}{x+3}=1-\dfrac{5}{x+3}\)
\(A\in Z\Rightarrow5⋮x+3\)
\(\Rightarrow x+3\in U\left(5\right)\)
\(U\left(5\right)=\left\{\pm1;\pm5\right\}\)
\(\Rightarrow\left\{{}\begin{matrix}x+3=1\Rightarrow x=-2\\x+3=-1\Rightarrow x=-4\\x+3=5\Rightarrow x=2\\x+3=-5\Rightarrow x=-8\end{matrix}\right.\)
\(B=\dfrac{2x+1}{x-3}=\dfrac{2x-6+7}{x-3}=\dfrac{2x-6}{x-3}+\dfrac{7}{x-3}=\dfrac{2\left(x-3\right)}{x-3}+\dfrac{7}{x-3}=2+\dfrac{7}{x-3}\)\(B\in Z\Rightarrow7⋮x-3\)
\(\Rightarrow x-3\in U\left(7\right)\)
\(U\left(7\right)=\left\{\pm1;\pm7\right\}\)
\(\Rightarrow\left\{{}\begin{matrix}x-3=1\Rightarrow x=4\\x-3=-1\Rightarrow x=2\\x-3=7\Rightarrow x=10\\x-3=-7\Rightarrow x=-4\end{matrix}\right.\)