OK, My book has a proof that a continious function defined on $[0,1]$ attains all values between $f(0)$ and $f(1)$ using some ultra case bashy stuff, but I have two different proofs, is those correct ?
(a) Let the desired value be $m$. We prove that there exists a sequence of reals $\{a_i\}_{i=0}^{\infty}$ such that $lim \; a$ exists, and $0 \leq a_i \leq 1$ for all $i$, satsifying $lim\; f(a_i) = m$. So, by the defination of cont
Construction: From the defination of continiuty, for $x \in [0,1]$ given any $\epsilon$, there exists a nonzero $h(\epsilon, x):= \delta$ such that for all $y$ with $|y - x| < \delta$, $|f(y) - f(x) | < \epsilon$ Let $g(\epsilon) := min\{h(\epsilon, x) | x \in [0,1]\}$.
Now, set $\epsilon_0 := 10^{-10000}$. split $[0,1]$ into $ \lfloor \frac{1}{g(\epsilon_0)} \rfloor $ equal intervals $I_1, I_2, \cdots, I_{\text{A big number}}$ , and let $a_0$ be the lower bound of the interval $I_i$, of which $\max{f(x) | x \in I_i} \geq m \geq \min{f(x) | x \in I_i}$.
Now, set $\epsilon_{1} = \epsilon_0^{100000}$, and divide the $I_i$ into $ \lfloor \frac{1}{g(\epsilon_1)} \rfloor $ equal interval, and choose $a_1$ to be the lower bound of the interval $I_{i_{j}}$ for which $\max{f(x) | x \in I_{i_{j}}} \geq m \geq \min{f(x) | x \in I_{i_{j}}}$
Repeat the process.
(b) Another proof: Assume WLOG $f(0) < f(1)$. Let the desired number be $m$. If $f(0) = m$ or $f(1) = m$, then we're done. Otherwise, divide the reals in $[0,1]$ into sets $L$ and $R$ such that:
- $y \in L$ if and only if $max\{ f(x) | 0 \leq x \leq y \} \leq a$
- Otherwise, put $y$ in $R$.
Now, $L$ exists because as $m \neq f(0)$, we can pick very small epsilon $\epsilon$ such that for $0 \leq x \leq \epsilon$, $f(x) < m$, and $R$ exists by the analogous arguement on $f(1)$.
Now it's well known that a number $y$ exists such that for all member of $L$ is smaller or equal to it, and all members of $R$ is larger or equal to it. As $y$ must be inside $[0,1]$, we're done.
There are fundamental issues with both approaches. You assume that things like $\min, \max$ exist. They do exist if the function under consideration is continuous but that's another deep theorem (extreme value theorem, EVT) which is at the same level of complexity as the intermediate value theorem (IVT) which you are trying to prove. Also the fact that $g(\epsilon) $ exists and is positive is a property which goes by the name uniform continuity. This seems to suggest that IVT depends on EVT or uniform continuity. This is not true.
The proof strategy works in both cases (I do have a few reservations about the choice of values of $\epsilon$ in first proof, you need to fix that somehow) but it is undeniably complicated and uses EVT unnecessarily. Moreover you have to establish that $f(a) =m$ in each of the proofs.
Much easier and simpler to understand proofs exist for IVT and all of them are based on different notions of completeness. I have presented a few proofs in this blog post.