MathCastle
Counting & ProbabilityChallengeAdvanced Number Theory

Advanced Number Theory · Challenge problem

Let NN be the number of permutations σ\sigma of {1,2,…,8}\{1, 2, \ldots, 8\} such that σ(i)≠i\sigma(i) \ne i and σ(i)≠i+1\sigma(i) \ne i + 1 for every ii (the second condition is empty for i=8i = 8). Find the remainder when NN is divided by 10001000.