# Prove that a subset $A$ of $X$ is dense if and only if every open subset of $X$ contain some point of $A$

Let $X,τ$ be a topological space. Prove that a subset $A$ of $X$ is dense if and only if every open subset of $X$ contain some point of $A$

this is what I got

Let $X,τ$ be a topological space

Part 1: Assume that a subset $A$ of $X$ is dense, show that every open subset of $X$ contain some point of $A$ Let $a∈A$, by axiom i) of the closure of set, $A⊂Cl A$, so $a∈Cl A$. Since $A$ is dense, $Cl A=X$, so $a∈X$. Let $ℵ_x$be the the collection of open neihborhood in $X$, by the axiom ii) of the open neighborhood system, $a∈X$ then $a∈N$ for each $N∈ℵ_x$. In other word, every open subset of $X$ contain some point of $A$.

Part 2: Assume that every open subset of $X$ contain some point of $A$, show that subset $A$ of $X$ is dense

I'm kinda stuck on how to show $Cl A=X$. I know that I need to show $Cl A⊂X$ and the other way around, but I'm not sure how.

The complement of the closed set $\operatorname{Cl}A$ is open and disjoint to $A$. By assumption the only open set disjoint to $A$ is the empty set.

Since every (non-empty) open subset of $X$ contains a point from $A$ it has to hold that

(1.) $\forall U \in \mathcal{O}(X)\setminus\{\emptyset\}: U \cap A \neq \emptyset$.

Because of $A \subseteq \mathcal{Cl}A$ it holds also that

(2.) $\complement \mathcal{Cl}A \cap A = \emptyset$

So let's take a look at the given complement: \begin{align*} \complement\mathcal{Cl}{A} &= \complement\bigcap_{U\in\mathcal{O}(X),A\subseteq \complement U}\complement U \\&= \bigcup_{U\in\mathcal{O}(X),A\subseteq \complement U} U =: U_0. \end{align*}

By definition, $U_0$ has to be an open set. By (2.) it follows that $U_0\cap A = \emptyset$. Then with (1.), $U_0$ has to be the empty set.

Therefore $\complement \mathcal{Cl}A = \emptyset$ and so $\mathcal{Cl}A = X$.