Let $a$ be an integer which is not divisible by 2 and 3. Prove that 24 divides $a^2-1$.
This, $a$ can be written as $a=2x+1$ or $a=3z+r$ where $r=1,2$ and $x$ and $z$ are integers. This $a^2-1= (2x+1)^2-1$ or $(3z+r)^2-1$
Taking first case : $4x^2+4x$
But, how to prove that it is divisible by 24? Is my method correct? Please give me some hints on how to do this.