Problem

Source:

Tags: modular arithmetic, number theory proposed, number theory



Let $n$ be a positive integer. $S$ is the set of nonnegative integers $a$ such that $1<a<n$ and $a^{a-1}-1$ is divisible by $n$. Prove that if $S=\{ n-1 \}$ then $n=2p$ where $p$ is a prime number. Mihai Cipu and Nicolae Ciprian Bonciocat