I'm not exactly sure how the intermediate value theorem can be applied to the following question especially with the defined function $g(x)$ which is provided below.

Using the intermediate value theorem with $g(x)=f(x)-x$ and suppose $f:[0,b] \to [0,b]$ is continuous. Prove there is at least one $c \in [0,b]$ such that $f(c)=c$.

Thanks