I'm trying to find an example of a function $g:\mathbb{R}\to \mathbb{R}$ (or $g:[1,\infty) \to \mathbb{R}$), so that $$|g(x_1)-g(x_2)|<|x_1-x_2|$$ for all $x_1, x_2\in \mathbb{R}$ ( or $x_1,x_2\in [1,\infty)$) and $x_1\neq x_2$ but $$g(x)=x$$ doesn't have a solution
Any ideas?
I think $g(x)=\frac{x}{2}$ works.