# Does there exist a continuous function $f :\mathbb{R} \rightarrow \mathbb{R}$ such that $f \circ f(x) = -x$ for all $x$? [duplicate]

Does there exist a continuous function $f :\mathbb{R} \rightarrow \mathbb{R}$ such that $f \circ f(x) = -x$ for all $x$?
Since $f$ is bijective, as $f^{-1} = -f$, and is continuous, $f$ needs to be increasing or decreasing. But the composition of increasing functions is increasing. And composition of decreasing functions is increasing.