Suppose $n|a^2-1$ where $a>1$ and n is odd. Show that $n=$gcd$(a-1,n)$gcd$(a+1,n)$.
Part 2
Show that if $a<n-1$ then this gives a nontrivial factorization of n
What I did:
I found the gcd$(a-1,a+1)$ which is $2$ if $a$ is odd and $1$ if $a$ is even. And that's it. I'm stuck