A natural number is a perfect square as well as a perfect cube. Show that it is $0$ or $1$ $($mod $7$$)$.
I tried the following.
There are integers numbers $x,y$ such that $n=x^{2}=y^{3}.$ By using Euclidean division, then $x$ and $y$ can be written as $7k,7k+1,7k+2,7k+3,7k+4,7k+5$ or $7k+6$. I am trying some contradictory stuff.
I don't know from where to go from here. Please suggest some hints.