Axiom of Completeness to prove intermediate value theorem I am having a little trouble understanding one of the steps in this proof.
From Stephen Abbott's Analysis:
Using AoC to prove the IVT:
TO simplify matters, consider $f$ as a continuous function which satisfies $f(a)<0<f(b)$
and show that $f(c) =0 $ for some $c \in (a,b)$. First let

Clearly we can see $K$ satisfies the axiom of completeness, and thus we can let $c = \sup K$
There are three cases to consider: $f(c) > 0, f(c)<0 \space \text{and} \space f(c) = 0$
Part where I have difficulty understanding the proof
. The author states:
"Since $c$ is the least upper bound of $K$, we can rule out the first two cases.
"
I don't understand how we can conclude this immediately?
Thinking about it, if $f(c)>0$, then $c \notin K$ so this would contradict $c$ being a least upper bound.(Right?)
However, how can we rule out $f(c)<0$? Here $c \in K$, which is a valid least upper bound?
 A: As Wojuvu said, it does require an extra step of proof.
First of all, the claim

Thinking about it, if $f(c)>0$, then $c\notin K$ so this would contradict c being a least upper bound.(Right?)

is not quite true. The least upper bound of a set $A$ does not need to be an element of the set. (Take the set $[0,1)$ and its least upper bound $1$, for example.) We need to do something a bit more delicate.
To rule out the two cases $f(c)>0$ and $f(c)<0$ in the proof you will need to use the continuity of $f$. (Note that the theorem requires a continuous mapping, as can be seen with some examples of step-functions, and we have not yet used continuity.) For both cases the idea is similar: if, for example you would have $f(c)>0$, then you should be able to find an $\varepsilon > 0$ such that for all points $z \in (c - \varepsilon,c) $ you have $f(z) > 0$. And this would be a contradiction with $c$ being the least upper bound.
A: Ruling out $f(c)<0$ requires a bit of work.
Suppose, for a contradiction, that $f(c)<0$. Note that $c \neq b$ so we can choose $\delta_1 > 0$ so that $[c, c+\delta_1]\subseteq[a, b]$. We know that $f$ is continuous, so in particular, $f$ is continuous at $c$. From the definition of continuity we can choose $\delta_2>0$ so that for all $t\in[a,b]$ we have 
$$
|t-c| < \delta_2 \implies f(t) < 0.
$$
Let $\delta = \min \{\delta_1, \delta_2\}$. Then $[c, c+\delta]\subseteq[a,b]$. Hence, for any $t\in[c, c+\delta]$ we have that $f(t)<y$. But then $c+\delta\in K$ which contradicts $c$ being the least upper bound. We conclude that we cannot have $f(c) < 0$.
As Rami Luisto pointed out in his answer, your reasoning for deducing that $f(c)>0$ is not quite right. However, you can use a similar approach as what I used above to prove it.
