Countable Basis Proof in Munkres

general-topology

Munkres writes the following:

Suppose that $X$ has a countable basis. Then there exists a countable subset of $X$ that is dense in $X$.

The proof:

From each nonempty basis element $B_n$, choose a point $x_n$. Let $D$ be the set consisting of the points $x_n$. Then $D$ is dense in $X$: Given any point $x \in X$, every basis element containing $X$ intersects $D$, so $x$ belongs to $\overline{D}$.

I don't understand why the bold statement is true. Why can't an open set containing $x$ have empty intersection with $D$?

Best Answer

If $x\in X$, every basis element $U$ containing $x$ is equal to $B_n$, for some natural $n$. But then $x_n\in B_n=U$. Since $x_n\in D$, this proves that $U\cap D\neq\emptyset$. Since every non-empty open set contains some basis element, this proves that every non-empty open set intersects $D$. In other words, $D$ is dense in $X$.