I personally think the best analogy for this is sudoku. Let's say you get down to a point where the only options for a spot are a $3$ and a $1$. You can't decide which to use, so you just go for the three. A few turns later, you end up with $2$ twos in the same row, so you know you must have made a mistake somewhere, but the only time you did something you were unsure of it when you put a $3$ in the original spot. Thus, there is no way that original spot had a $3$ in it, so it must have a one in it.
Likewise, let's say you are trying to prove a statement. There are two possibilities: it is true, or it is false. If you decide to "guess" that it is false, and later on end up at something totally impossible, then you know that somewhere along the line you must have messed up. But the only time you did something you were uncertain of is when you assumed the statement was false. Thus, the statement couldn't possibly be false, so it must be true.
Let's run through a simple example. I want to prove that there is no largest natural number. Well there are two possibilities, either that statement is true, or it is false. Well let's see what happens if I "guess" it to be false. Well, if the statement is false, then that means that there is some largest natural number, let's call it $N$. But now, I claim that that is absurd because $N+1$ is always greater than $N$, so somewhere along the line I must have made a mistake. Well, the only step I was uncertain about was assuming that there was a largest natural number, so that must be the bad step, and therefore there cannot possibly be a largest natural number.