Closure of union of two sets

Your second attempt only needs one more fact: $(A \cup B)' = A' \cup B'$.

To see this: pick $x \in A'$. Then every neighbourhood $U$ of $x$ intersects $A$ in at least one point different from $x$. This point is also in $A \cup B$, so then every neighbourhood of $x$ intersects a point of $A \cup B$ not equal to $x$, so $x \in (A\cup B)'$. Similarly, if $x \in B'$, $x \in (A \cup B)'$, so we have $A' \cup B' \subset (A \cup B)'$.

On the other hand, if $x \in (A \cup B)'$, we need to show $x$ is in $A' \cup B'$. So assume not, $x \notin A'$, which means there is a neighbourhood $U$ of $x$ that intersects $A$ in an empty set or just $\{x\}$. Also $x \notin B'$, so there is a neighbourhood $V$ of $x$ such that $V$ intersects $B$ either in the empty set or $\{x\}$. Now, $U \cap V$ is a neighbourhood of $x$, and $(U \cap V) \cap (A \cup B) = (U \cap V \cap A) \cup (U \cap B \cap V) \subset (U \cap A) \cup (V \cap B)$, which is also either the empty set or $\{x\}$, from the properties of $U$ and $V$. But this contradicts that $x \in (A \cup B)'$. So our assumption was incorrect: $x$ must be in $A' \cup B'$, as required.


You have only proved that $\overline A\cup\overline B$ is closed. You must prove two things more:

  1. $A\cup B\subset\overline A\cup\overline B$. This is very easy.
  2. Every closed set that contains $A\cup B$ also contains $\overline A\cup\overline B$. This is not so easy.

Some hints for the second part: Consider a closed set $F$ that contains $A\cup B$. Suppose now that there is some $x\in\overline A\cup\overline B$ such that $x\notin F$. Then $x$ can be in $\overline A$ or in $\overline B$.
If it is in $\overline A$, for example, consider an open neighbourhood $U$ of $x$. Now, since $x\notin F$, consider an open neighbourhood $V$ of $x$ such that $F\cap V=\emptyset$. What is $U\cap V$? Is empty $U\cap V\cap A$? Can you arrive at a contradiction?
The other possibility is that $x\in\overline B$. Can you make the same reasoning?