I'm having trouble understanding the indicated line from the solutions
Do a proof by contradiction by assuming there exists an $a > 1$ such that $a \mid \frac{n}{d}$ and $a \mid \frac{m}{d}$.
This implies (I don't understan why!) $ad\mid n$ and $ad\mid m$,
but $ad>d = \gcd(m,n)$, a contradiction.