# Examples of functions of class C^infinity

Examples of functions $f,g:\mathbb{R}\to\mathbb{R}$ of class $C^\infty$ that satisfy:
(1) $f(x)=0\Leftrightarrow 0\leq x\leq 1;$
(2) $g(x)=x$ if $|x| \leq 1$, and $|g(x)|<|x|$ if $|x|>1$