Let $(X,\tau)$ be a Hausdorff space. $A,B \subseteq (X,\tau)$ which are compact sets. Show that the intersection and the union of A and B are compact sets.
Here is the what i did so far but i think there are some points that is not fit, i can feel but can't figure out :) thanks advance for guidince.
Proof:
Every compact subset of Hausdorff space is closed set. So, $A,B \subseteq X$ which are compact sets are closed sets. Thus $A \cup B$ and $A \cap B$ are closed sets (By the previous topologicial theorem which is union and intersection of two closed sets are closed set.) As a result of this $X \setminus (A \cup B)$ and $X \setminus (A \cap B)$ are open sets (By the definition of closed set.)
Let $\mathcal{U}$ is cover for $A \cup B$. Because of $X \setminus (A \cup B)$ is copen set, we can write a cover for the Hausdorff space which is given as $X \subseteq \mathcal{U} \cup (X \setminus (A \cup B) ) $ .Thus, By being compact set, for every cover of X there exists a finite subcover of X. So difference of the finite subcover and $X \setminus A \cup B$ gives us a finite subcover of $A \cup B$.
Let $\mathcal{V}$ is cover for $A \cap B$. Because of $X \setminus (A \cap B)$ is copen set, we can write a cover for the Hausdorff space which is given as $ X \subseteq \mathcal{V} \cup (X \setminus (A \cap B) ) $.Thus, by being compact set, for every cover of X there exists a finite subcover of X. So difference of the finite subcover and $X \setminus A \cap B$ gives us a finite subcover of $A \cap B$