A question regarding dense subsets Let $M$ be a metric space. Let $A$ and $B$ be dense subsets of $M$ such that $A$ is open. Then prove that $A \cap B$ is dense in $M$. I’m really stuck at this problem. Any hints or solutions will be highly appreciated.
 A: In these problems all you have to do is take a big breath:
Take an element $s \in M$. Since $A$ is dense then there exist a sequence $a_n \in A$ such that $a_n\rightarrow s$. Because $A$ is open there exists open balls $B_n(a_n,e_n)\subset A$ (with center $a_n$ and radius $e_n$). Without loss of generality we can assume that $e_n \rightarrow 0$ (show this).
Since $B$ is dense there exists a sequence $b_n$ in $B$ such that for every $n$ 
 ,we have $b_n \in B_n$.
Because $e_n\rightarrow 0$ we have hat $d(b_n,a_n)\rightarrow 0$and becuase $a_n \rightarrow s$ so does $b_n$.
We are done , since, by construction, $b_n$ lies both in $B$ and $A$. 
A: Let $U \subset M$ be any non-empty open subset. Since both $U$ and $A$ are open, so is $U \cap A$. But since $A$ and $B$ are dense in $M$, we have $U \cap A \neq \emptyset$, $U \cap B \neq \emptyset$ and also $(U \cap A) \cap B = U \cap (A \cap B) \neq \emptyset$ and we are done, because $U$ was arbitrary (and open) with non-empty intersection with $A \cap B$.
Note the importance of $A$ being open, otherwise $U\cap A$ would not.
As a counter example, take $M = \mathbb{R}$, $A = \mathbb{Q}$ and $B = \mathbb{R - Q}$. None of $A$ and $B$ are open, even though they are dense in $\mathbb{R}$. We have $ A \cap B =\mathbb{Q} \cap (\mathbb{R - Q}) = \emptyset$, which is obviously not dense in $\mathbb{R}$.
A: A set is dense in $M$ if and only if it intersects every nonempty open subset of $M$.
Let $U \subseteq M$ be an arbitrary nonempty open set. The intersection $U \cap A$ is nonempty since $A$ is dense in $M$, and it is also open since both $U$ and $A$ are open.
Then $$U \cap (A \cap B) = \underbrace{(U \cap A)}_{\text{nonempty open set}} \cap B$$ is nonempty since $B$ is dense in $M$. 
A: First prove the important lemma (cl = closure)
open U implies U ∩ cl A subset cl(U ∩ A).  
Thus A = A $\cap$ cl B subset cl(A $\cap$ B).
Whence M = cl A subset cl(A $\cap$ B).
