compactness and continuity in metric spaces Any help please with the following problem?
Let $f:X\rightarrow Y$  be a continuous one-to-one and surjective mapping between
compact metric spaces. Prove that the inverse mapping $f^{-1}:Y\rightarrow X$ is continuous.
I tried the following: I assumed $C$ a subset of $X$, then by compactness of $X$, C is also compact and hence it is closed. $f$ is continuous and $C$ is compact, then $f(C)$ is compact and hence it is closed. Any help how to go from here to prove that $f^{-1}$ is continuous?

It is a standard fact that a function $g : A \to B$ is continuous if and only if the inverse image of every closed $C \subseteq B$ is closed in $A$. [It is good to compare this with the definition of continuity, which says that the inverse image of open sets is open.] If you have not done so already, I recommend that you show this fact as an exercise. Thus to prove $f^{-1} : Y \to X$ is continuous, it suffices to show that $f$ is a closed map; i.e., the (forward) image of every closed set in $X$ is closed in $Y$. 
You have almost showed this final statement. However your proof has a small, but important, error. It is not true that if $C \subseteq X$, then $C$ is compact. However, if $C$ is closed in $X$ (which itself is compact), then it is true that $C$ is compact. The rest of your proof then carries over as written.
