I know this is an easy question, but I cannot demonstrate it properly.
Suppose by contradiction that $A \cap \bar{Y} \neq \emptyset$. Then $\exists \ x \in A \cap \bar{Y}$.
I need help formalizing this reasoning (or correcting if it is wrong)
By the definition of $A$ open, $\exists \ U \subset A$ open neighborhood of $x$. Then my idea is to prove that $U \cap Y \neq \emptyset$ because $U$ in somewhat sense "touches" $Y$, because it's a neighborhood of $x$. But i can't write down a formal demonstration. Any help is appreciated. Thanks^^