Hacker News new | ask | show | jobs
by namelessUser 1917 days ago
If a^n = 0 (or 1) mod b, then a^(kn) = (a^n)^k = 0 (or 1) mod b for any positive integer k.

Therefore you need to pick a common multiple of 6 and 10.