The determinant of a given square matrix $A$, with rational entries, equals 1. It is known that all entries of $A^{2015}$ are integers. Is it true that all entries of $A$ are integers?
My attemt: I've tried to construct a counter example but failed. I believe it's true but don't know how to prove it.
Let $A = \left( \begin{array}{ccc} 1 & \frac{1}{2015} \\ 0 & 1\end{array} \right)$, then $A^{2015} = \left( \begin{array}{ccc} 1 & 1 \\ 0 & 1\end{array} \right)$.