Fixed point in a continuous map 
Possible Duplicate:
Periodic orbits 

Suppose that $f$ is a continuous map from $\mathbb R$ to $\mathbb R$, which satisfies $f(f(x)) = x$ for each $x \in \mathbb{R}$.
Does $f$ necessarily have a fixed point?

Here's a somewhat simpler (in my opinion) argument.  It's essentially the answer in Amr's link given in the first comment to the question, but simplified a bit to treat just the present question, not a generalization.  Start with any $a\in\mathbb R$.  If we're very lucky, $f(a)=a$ and we're done.  If we're not that lucky, let $b=f(a)$; by assumption $a=f(f(a))=f(b)$.  Since we weren't lucky, $a\neq b$.  Suppose for a moment that $a<b$.  Then the function $g$ defined by $g(x)=f(x)-x$ is positive at $a$ and negative at $b$, so, by the intermediate value theorem, it's zero at some $c$ (between $a$ and $b$).  That means $f(c)=c$, and we have the desired fixed point, under the assumption $a<b$.  The other possibility, $b<a$, is handled by the same argument with the roles of $a$ and $b$ interchanged.
As user1551 noted, we need $f(f(x))=x$ for only a single $x$, since we can then take that $x$ as the $a$ in the argument above. 
