Understanding of the proof of "intermediate value thm" 

Theorem. Let $f$ be a continuous function from $[a,b] \rightarrow \mathbb{R}$, and $f(a) \not = f(b)$. Then for all C between $f(a)$ and $f(b)$, there exists some point $c$ in $[a,b]$ such that $f(c)=C$.
Proof
Let $f(a)<f(b)$, then $f(a)<C<f(b)$, and Let $E:= \{ x \in [a,b] | f(x) <C \}$. It is obvious that $a\in E$ so that $E \not = \varnothing$. Also, $E \subseteq [a,b]$ so $E$ is bounded. By the completeness axiom there exists $c:=\sup E$. Now, show that $f(c) = C$.
By the property of supremum, $\forall n,\exists x_n \in E : c - 1/n < x_n \leq c$.  Then by the definition of $E$, $f(x_n) < C$.


I understand well the above part but I don't understand the following part.


Next, for $f$ is continuous on $b$ and $C < f(b)$, there exists $\delta >0, [|x-b|<\delta \Rightarrow C<f(x)]$. So we can say thay $c<b$.


How can one derive this statement? I agree that if we choose adequate $\epsilon>0$ and then $\exists \delta : [|x-b|<\delta \Rightarrow |f(x)-f(b)|<\epsilon]$. The last part of this that $[|f(x)-f(b)| <\epsilon]$ can imply that $C<f(x)$ if we choose some adequate $\epsilon$. However, I don't understand how one can derive $c<b$. Explain me more detailed.
 A: The first questioned statement follows by taking $\epsilon < \frac{|f(b)-C|}{2}$.  This is the "adequate" epsilon as it was called in the posting.
The second questioned assertion, $c < b$, follows because $f(x)$ is continuous at $b$, so that on some interval $(u,b]$ the values of the function will be close to $f(b)$ and thus bounded away from $C$ (the supposed value of $f(c)$).  Then $c \leq u < b$.
A: Since $f(b) > C$, choose an $\eta > 0$ so that $f(x) > C$ for all $x \in (b - \eta, b)$.  So $b - \eta$ certainly bounds $E$, hence $\sup E \le b - \eta < b$
A: First notice this basic (really basic/evident) property of continuous functions:
If $f$ is continuous at $a$ and $f(a) > 0$ then there is a neighborhood of $a$ (say of type $(a - \delta, a + \delta)$ in which $f$ is positive.
This is almost obvious because when $x$ is near $a$ then $f(x)$ should be near $f(a)$ (this the meaning of continuity of $f$ at $a$). Since $f(a)$ is positive if we make $f(x)$ too close to $f(a)$ then $f(x)$ will also be positive. The definition of continuity ensures that it is possible to make $f(x)$ arbitrary close to $f(a)$ by choosing $x$ sufficiently close to $a$. Hence we have a neighborhood of $a$ in which $f$ is positive.
Similarly it follows that if $f$ is continuous at $a$ and $f(a) < 0$ then there is a neighborhood of $a$ in which $f$ is negative.
Let's get back now to the current question. Since $f(b) > C$ therefore $g(x) = f(x) - C$ is such that $g(b) > 0$ and $g$ is continuous at $b$. Hence there is a neighborhood of $b$ in which $g$ is positive. So there is a neighborhood of $b$ in which $f(x) > C$. Since $f(x)$ is not defined for $x > b$ the neighborhood above needs to be taken of the form $[b - h, b]$. It follows that none of points in this neighborhood belong to set $E$ (since for $x \in E$ we have $f(x) < C$).
Next we obviously know that $c \leq b$. If $c$ were equal to $b$ then there would be a member $x \in E$ such that $c - h < x \leq c$ i.e. $b - h < x \leq b$. But we have already noted that no point of the interval $[b - h, b]$ belongs to set $E$. Hence we can't have $c = b$ and therefore $c < b$.
