As everybody knows
$\phi (p^r) = (p-1)p^{r-1}$
where $\phi$ is the Euler's totient function and $p$ is a prime number. We might see this formula as the cardinality of the set of units of $\mathbb{Z}/p^r \mathbb{Z}$, i.e $\phi(p^r) = \vert (\mathbb{Z}/p^r \mathbb{Z})^{\times} \vert$.
Now, let me call $R= \mathbb{Z}/p^r \mathbb{Z}$. Clearly, in $R$ we have the ideal $J=(p+p^r\mathbb{Z})=p\mathbb{Z}/p^r \mathbb{Z}$ which is nilpotent. Furthermore, we know that $x \in R$ is a unit iff $x+J$ is a unit in $R/J$ (this holds with general ring $R$ and $J$ nilpotent). Using this fact I want to recover the first equality. Any hints?
My idea is to find something like that
$\phi (p^r) = \vert (\mathbb{Z}/p^r \mathbb{Z})^{\times} \vert= (p-1) \vert J \vert =(p-1)p^{r-1}$
The first and the last equalities are ok, but what about the middle one?
$\lvert (R/J)^\times\rvert$ is not equal to $(p-1)\lvert J\rvert$, but to $p-1$, period: if anything, it's the cardinaliy of its preimage by the quotient map $x\mapsto x+J$ to have that cardinality. Anyways, call $\pi:\Bbb Z\to\Bbb Z/p^r\Bbb Z$ the map $x\mapsto x+p^r\Bbb Z$. Since the map is surjective, $R/J\cong \Bbb Z/(\pi^{-1}(J))=\Bbb Z/p\Bbb Z$