Prove that $[0,1]$ isn't homeomorphic to $\mathbb{R}$ Prove that $[0,1]$ isn't homeomorphic to $\mathbb{R}$
My first thought is that there can not be a continuous bijection, $f$, from $[0,1]$ to $\mathbb{R}$ because a continuous function that maps $[0,1]\rightarrow \mathbb{R}$ must be bounded so there can't be a surjection. So that would then be the proof. 
Though I believe I am incorrect in my thinking because a hint for the assignment says to use the intermediate value theorem. That is "Suppose $f:[a,b]\rightarrow\mathbb{R}$ is continuous. If $f(a)<\delta<f(b)$ or $f(b)<\delta<f(a)$ then $\delta=f(c)$ for some $c\in[a,b]$". 
Why is my first thought wrong and how is the IVT useful?

Here's a way to use the IVT: Suppose $f: \mathbb{R}\rightarrow [0, 1]$ is a continuous bijection. Let $a\in\mathbb{R}$ be such that $f(a)=0$; now look at $x=a-1$ and $y=a+1$. Since $f$ is injective, we have $f(x), f(y)\not=0$; let $0<c<\min\{f(x), f(y)\}$. By IVT, we have $f(x')=c$ for some $x<x'<a$ and $f(y')=c$ for some $a<y'<y$; but then $x'\not=y'$ but $f(x')=f(y')$, so $f$ is not injective. Contradiction.
