Let $W ,X$ and $Y$ be three sets and let $f :W \to X$ and $g: X \to Y$ be two functions. Consider the composition $g \circ f: W \to Y $ which, as usual, is defined by $(g\circ f)(w)=g(f(w))$ for $w \in W$.
$(a)$ Prove that f $Z\subseteq Y$, then $(g\circ f)^{-1}(Z)=f^{-1}(g^{-1}(Z)).$
$(b)$ Deduce that if $(W,c) ,(X,d)$ and $(Y,e)$ are metric spaces and the functions $f$ and $g$ are both continuous, then the function $g \circ f$ is continuous.
Definitions:
- Let $(X, d)$ and $(Y, e)$ be metric spaces, and let $x \in X$. A function $f : X \to Y$ is continuous at $x$ if: $\forall B \in \mathcal B(f(x)) \exists A \in \mathcal B(x) : f(A) \subseteq B$