5.6. (Yugoslavia, 83). Find all values of $n \in \mathbf{N}$ that have the following property: if the numbers $n^{3}$ and $n^{4}$ are written next to each other (in the decimal system), then in the resulting record each of the 10 digits $0,1, \ldots, 9$ will appear exactly once.