\(\left(\left|x\right|-2017\right)^{\left(n+2018\right)\left(n+2019\right)}=-\left(2^3-3^2\right)^{2019}\)
\(\left(\left|x\right|-2017\right)^{\left(n+2018\right)\left(n+2019\right)}=-\left(-1\right)^{2019}=1\)
\(\Rightarrow\orbr{\begin{cases}\left(n+2018\right)\left(n+2019\right)=0\\\left|x\right|-2017=1\end{cases}}\)
\(\Rightarrow\orbr{\begin{cases}\orbr{\begin{cases}n=-2018\\n=-2019\end{cases}}\\\orbr{\begin{cases}x=2018\\x=-2018\end{cases}}\end{cases}}\)