I know this is a trivial question, but it has been bothering me for a while.

My textbook says "Proof of contradiction exploits the fact that the statement "if A holds, then B holds" is equivalent to the statement "if B does not hold, then A does not hold". So far, okay. But how can we put the proof of $\sqrt2$ being an irrational number into this framework?

Every relevant proof that I've seen derives a contradiction by assuming that $\sqrt2$ is a rational number. In this case, what is the statement B? Is it "$\sqrt2$ is a irrational number"? Then, what is the statement A?