TITLE: Continuous function from $[0,1]$ to $[0,1]$
QUESTION [10 upvotes]: Does there exist a continuous function $f:[0,1]\rightarrow [0,1]$ such that $f$ takes every value in $[0,1]$ an infinite number of times?

REPLY [25 votes]: Yes.  In fact, there exists such an $f$ taking every value uncountably many times. 
Take a continuous surjection $g: [0, 1] \to [0, 1]^2$.  (Such things exist: they're space-filling curves.)  Then the composite $f$ of $g$ with first projection $[0, 1]^2 \to [0, 1]$ has the required property.

REPLY [17 votes]: Take a projection of a well-known Peano curve, which is a surjective continuous mapping $[0,1] \to [0,1]^2$ to a factor.