# Closed subset of closed subspace is closed in a metric space (X,d)

Is it possible for the following to hold in metric spaces? Let (X,d) be a metric space,if A is closed in Y and Y is closed in X then A is closed in X. If possible someone could assist me for a proof. Here I try:Since A is closed in Y, then I want to write A=U∩Y, where U is closed in X. But Y is closed in X,hence A is the intersection of two closed sets in X.Can this be applied here? Thanks

-
I've tried to make the title more descriptive - I hope you don't mind. I believe having good title is important, see How can I ask a good question?. –  Martin Sleziak Apr 17 '12 at 14:08
Your proof is OK. Congratulations –  Xabier Domínguez Apr 17 '12 at 14:18

Suppose $a_n\in A$ for all $n$ and $a_n\to x$. Since $a_n\in Y$ and $Y$ is closed, $x\in Y$. Now the closedness of $A$ in $Y$ implies $x\in A$ as required.