<s>[INST] Why does the discriminant tell us how many zeroes a quadratic equation has? The quadratic formula states that:
$$x = \frac {-b \pm \sqrt{b^2 - 4ac}}{2a}$$
The part we're interested in is $b^2 - 4ac$ this is called the discriminant.
I know from school that we can use the discriminant to figure out how many zeroes a quadratic equation has (or rather, if it has complex, real, or repeating zeroes).
If $b^2-4ac > 0$ then the equation has 2 real zeroes.
If $b^2-4ac < 0$ then the equation has 2 complex zeroes.
If $b^2-4ac = 0$ then the equation has repeating zeroes.

But I don't uderstand why this works.
 [/INST] Well if $a \ne 0$
$ax^2 + bx + c = 0 \iff$
$x^2 + \frac bax = -\frac ca \iff$
$x^2 + \frac bax + \frac {b^2}{4a^2} = \frac {b^2}{4a^2}- \frac ca \iff $
$x^2 + 2*\frac {b}{2a}x +(\frac {b}{2a})^2 = \frac {b^2 - 4ac}{4a^2} \iff $
$(x + \frac b{2a})^2 = \frac {b^2 - 4ac}{4a^2} \iff $
$x + \frac b{2a} = \pm \sqrt{\frac {b^2 - 4ac}{4a^2}} \iff $
$x + \frac b{2a} = \pm \frac {\sqrt{b^2 - 4ac}}{\pm 2a} \iff $
$x + \frac b{2a} = \pm \frac {\sqrt{b^2 - 4ac}}{2a}\iff $
$x = -\frac b{2a}  \pm \frac {\sqrt{b^2 - 4ac}}{2a}\iff $
$x = \frac { -b \pm \sqrt{b^2 - 4ac}}{2a}$
Now three things can happen:
1) $b^2 - 4ac < 0$
If so then $\sqrt{b^2 - 4ac}$ is not a real number.  So
$x = \frac { -b \pm \sqrt{b^2 - 4ac}}{2a}$ is never a real number.
So $ax^2 +bx +c = 0$ is impossible for any real x.  
There are no real solutions.
2) $b^2 - 4ac = 0$
Then $\sqrt{b^2 - 4ac} = 0$
Then $x = \frac { -b \pm \sqrt{b^2 - 4ac}}{2a}$ would mean $x = \frac {-b}{2a}$.
So $ax^2 + bx + c = 0$ is only possible if (and will be possible if) $ x = \frac {-b}{2a}$.  And so $ax^2 + bx + c = 0$ has exactly one solution when $x = \frac {-b}{2a}$.
or 3)
$b^2 - 4ac > 0$
Then $\sqrt{b^2 - 4ac} = k > 0$
then $\frac { -b + \sqrt{b^2 - 4ac}}{2a}$ and $\frac { -b - \sqrt{b^2 - 4ac}}{2a}$  are two different numbers.
And $ax^2 + bx + c = 0 \iff x = \frac { -b + \sqrt{b^2 - 4ac}}{2a}$ or $x =  \frac { -b - \sqrt{b^2 - 4ac}}{2a}$.
So $ax^2 +bx + c = 0$ has exactly two solutions. They are $x = \frac { -b + \sqrt{b^2 - 4ac}}{2a}$ or $x =  \frac { -b - \sqrt{b^2 - 4ac}}{2a}$
</s>