= Solution
Write
$$
A=\bigcap_{n=1}^\infty U_n
$$
with each $U_n$ open. The closed sets $A$ and $X\setminus U_n$ are disjoint. By the <Urysohn lemma>, choose a continuous $f_n:X\to[0,1]$ with
$$
f_n=0\text{ on }A,
\qquad
f_n=1\text{ on }X\setminus U_n.
$$
The uniformly convergent series
$$
f(x)=\sum_{n=1}^\infty2^{-n}f_n(x)
$$
defines a continuous map to $[0,1]$. It vanishes on $A$. If $x\notin A$, then $x\notin U_n$ for some $n$, so $f_n(x)=1$ and $f(x)>0$. Thus
$$
\boxed{f^{-1}(0)=A,}
$$
which is the <closed G-delta set as a zero set> construction.
Back to article page