\(A=\frac{x^2-64+5}{x+8}=x-8+\frac{5}{x-8}\)
Để A nguyên \(\Rightarrow5⋮\left(x-8\right)\Rightarrow x-8=Ư\left(5\right)=\left\{-5;-1;1;5\right\}\)
\(\Rightarrow x=\left\{3;5;9;13\right\}\)
\(B=\frac{x+2}{x^2+4}\)
Do \(x\in Z\Rightarrow\left|x+2\right|\le\left|x\right|+2\le x^2+2< x^2+4\)
\(\Rightarrow\frac{\left|x+2\right|}{x^2+4}< 1\Rightarrow-1< \frac{x+2}{x^2+4}< 1\)
\(\Rightarrow\frac{x+2}{x^2+4}=0\Rightarrow x=-2\)