Solution (source code)

= Solution

Euler's totient is $\phi(n)=|\{1\le a\le n:(a,n)=1\}|$, equivalently the number of units modulo $n$.