A subset $A$ is a $G_{\delta}$ subset if $A=\bigcap_{1}^{\infty} G_i$ is a countable intersection of open sets $\{ G_i \}$. Show that in metric space $(X,d)$, every closed set is a $G_\delta$ set. If $A$ is a $G_\delta$ subset of a complete metric space $(X,d)$ show that there is metric $D$ on $A$ that induces the same convergence as $d$ on $A$, but $(A,D)$ is complete.
For the first part of the question, I take a closed set $C$, define $d(x,C)=\inf\{d(x,b):b\in C\}$, then let $G_k=\{x\in X: d(x,C)<\frac{1}{k}\}$, prove $G_k$ is open and $C=\bigcap G_k$. But to the second part, I really don't know where to start. My professor showed in his lecture notes that, if $O$ is an open set in $(X,d)$, define $D(x,y)=d(x,y)+|\frac{1}{d(x,O^C)}-\frac{1}{d(y,O^C)}|$, then $(O,D)$ is complete. I understand why this works. But in a $G_\delta$ set $A$, $A$ could be closed, and I have difficulty defining metric at the boundary. I tried $D(x,y)=\begin{cases} d(x,y)+|\frac{1}{d(x,O^C)}-\frac{1}{d(y,O^C)}| &\quad d(x,O^C)\cdot d(y,O^C) \neq 0\\d(x,y) &\quad otherwise \end{cases}$, but it seems to fail that it doesn't satisfy triangular inequality. Any hint for this? Thank you!