direct proof:
Suppose \(n^2\) is odd,
let \(n^2=2k+1\), for some \(k\in Z\).
\(n^2-1=2k\) is even.
\(\Rightarrow (n+1)(n-1)=2k\)
Because \((n+1)\) and \((n-1)\) are even.
Therefore, \(n\) is odd. Q.E.D.
proof by contrapositive:
Show that \(n\) is even, then \(n^2\) is even.
Suppose \(n=2k\) for some \(k\in Z\),
then \(n^2=(2k)^2=4k^2=2(2k^2)\) is even. Q.E.D.
proof by contradiction:
Suppose \(n^2\) is odd, then \(n\) is even.
Show that suppose is wrong.
let \(n=2k\), for some \(k\in Z\).
Thus, \(n^2=(2k)^2=4k^2=2(2k^2)\) is even.
This is contradiction from your suppose.
Therefore, \(n\) is odd. Q.E.D.