#### Problem 98E

98. At what numbers is the following function $g$ differentiable?

$$g(x)=\left\{\begin{array}{ll}2 x & \text { if } x \leqslant 0 \\2 x-x^{2} & \text { if } 0<x<2 \\2-x & \text { if } x \geqslant 2\end{array}\right.$$

Give a formula for $g^{\prime}$ and sketch the graphs of $g$ and $g^{\prime}$.