Reading this entry on logical connectives from Gower's blog, I found the following statement with proof.
Proposition: If $\sqrt{2}$ is rational then there is an integer that is both even and odd.
Proof. If $\sqrt{2}$ is rational, then we can find positive integers $p$ and $q$ such that $\sqrt{2}=p/q$, which implies that $2q^2=p^2$. Let $k$ be the largest integer such that $p^2$ is a multiple of $2^k$. Since $p^2$ is a perfect square, $k$ must be even. (To see this, just consider the prime factorization of $p$.) But $p^2=2q^2$, and the largest $k$ for which $2q^2$ is a multiple of $2^k$ is odd. (To see this, just consider the prime factorization of $q$.) Therefore, $k$ is both even and odd, which proves the result.
Now, I just don't get two things (somebody could say, considering how relevant those things are, the entire argument...):
1) Since $p^2$ is a perfect square, $k$ must be even.
2) But $p^2=2q^2$, and the largest $k$ for which $2q^2$ is a multiple of $2^k$ is odd.
Why is the case?
Any insight is greatly appreciated.