Disjoint Compact Sets in Hausdorff Space have Disjoint Neighborhoods/Lemma

Theorem
Let $\left({X, \tau}\right)$ be a Hausdorff space.

Let $C$ be a compact subspace of $X$.

Let $x \in X \setminus C$.

Then there exist open sets $U$ and $V$ such that $x \in U$, $C \subseteq V$, and $U \cap V = \varnothing$.

Proof
Let $\mathcal F$ be the set of all ordered pairs $\left({A, B}\right)$ such that $A$ and $B$ are open, $x \in A$, and $A \cap B = \varnothing$.

Then by the definition of Hausdorff space, for each $y \in C$ there exists an element $\left({A, B}\right) \in \mathcal F$ such that $y \in B$.

Thus the image of $\mathcal F$ covers $C$.

By the definition of compactness, there exists a finite subset $\mathcal G \subseteq \mathcal F$ such that $\displaystyle C \subseteq V = \bigcup \operatorname{Im} \left({G}\right)$.

Then $\operatorname{Im}^{-1} \left({G}\right)$ is also finite, so by the definition of a topology:


 * $\displaystyle U = \bigcap \operatorname{Im}^{-1} \left({G}\right)$ is open.

Then $x \in U$, $C \subseteq V$, and $U \cap V = \varnothing$.