n^2-2 chia hết cho n+3
mà n^2 chia hết cho n+3 suy ra 2chia hết cho n+3 suy ra n+3thuộc Ư(2)={1;2}
vậy n= -2;-1
\(n^2-2⋮n+3\)
\(\Rightarrow\hept{\begin{cases}n^2-2⋮n+3\\n^2+3n⋮n+3\end{cases}}\)
\(\Rightarrow n^2+3n-\left(n^2-2\right)⋮n+3\)
\(n^2+3n-n^2+2⋮n+3\)
\(3n+2\) \(⋮n+3\)
\(\Rightarrow\hept{\begin{cases}3n+2⋮n+3\\3n+9⋮n+3\end{cases}}\)
\(\Rightarrow3n+9-\left(3n+2\right)⋮n+3\)
\(3n+9-3n-2⋮n+3\)
\(7\) \(⋮n+3\)
\(\Rightarrow n+3\inƯ\left(7\right)=\left\{1;-1;7;-7\right\}\)
Ta có bảng sau :
\(n+3\) | 1 | -1 | 7 | -7 |
\(n\) | -2 | -4 | 4 | -10 |
Vậy \(n\in\left\{-2;-4;4;-10\right\}\)