Prove that if $f:[a,b]\to\Bbb{R}$ is one to one and has the intermediate value property, then $f$ is strictly monotone I got this problem:
Prove that if $f:[a,b]\to\Bbb{R}$ is one to one and has the intermediate value  property, then $f$ is strictly monotone.
That is, we must show that $\forall x,y\in[a,b], x<y \to f(x)<f(y)$ or $\forall x,y\in[a,b], x<y \to f(x)>f(y)$.
Start of my proof: 
Suppose not. 
That is suppose that $\exists x_1,y_1\in[a,b], x_1<y_1 \,\,and\,\, f(x_1)\geq f(y_1)$ and suppose that $\exists x_2,y_2\in[a,b], x_2<y_2 \,\,and\,\,\, f(x_2)\leq f(y_2)$.
Now since $f$ is one to one we get that $\exists x_1,y_1\in[a,b], x_1<y_1 \,\,\,and f(x_1)> f(y_1)$ and that $\exists x_2,y_2\in[a,b], x_2<y_2 \,\,and \,\,\,f(x_2)< f(y_2)$.
Now I am not sure how to split the proof into cases?
Thanks on any hints.

Edit: Suppose your function is not monotone, then there are four points such that $y_1<y_2$
and $y_3<y_4$ and $f(y_1)<f(y_2)$ and $f(y_4)<f(y_3)$. So we can take three of these four points and organize then in a increasing order 
$x_1<x_2<x_3$ such that  $f(x_1)< f(x_3)<f(x_2)$, $f(x_2)< f(x_1)<f(x_3)$, $f(x_2)< f(x_3)<f(x_1)$,  or $f(x_3)< f(x_1)<f(x_2)$, since $f$ is one to one, the values of $f(x_i)\,\,\,i=1,2,3$ can not be the same, suppose the first case, the others are similar. Since your function has the property of the intermidiate value, we have that  exists   $x_4\in (x_1,x_2)$ such that $f(x_4)=f(x_3)$ what is a contradiction, since the function is one to one. The same argument is valid for the others cases.
