Prove that the set $E = \{y ∈ Y : f(y) = g(y)\}$ (a.k.a. the coincidence set of $f$ and $g$) is closed in $Y$ The full question is:

Let $X$ be a Hausdorff topological space.

(i) Let $Y$ be a topological space and $f, g : Y → X$ be continuous functions.
Prove that the set
$$E = \{y ∈ Y : f(y) = g(y)\}$$
(a.k.a. the coincidence set of $f$ and $g$) is closed in $Y$

I know that the Hausdorff property of X allows me say something about distinct elements of $X$ i.e. $f(y)\neq g(y)$ and I know that I can use the fact that $f$ and $g$ are continuous to relate closed sets in Y to closed sets in $X$. However I am not quite sure how to use the Hausdorff property of X to help me.
$f-g$ is continuous again, hence $E = (f-g)^{-1}(\{0\})$ is the inverse image of a closed set with respect to a continuous map. So $E$ is closed.

The Hausdorff property is used really subtle: You need it to make sure that $\{0\}$ is closed.

Ok, if $X$ has no vector-space structure, we need to the following:

Consider $h:Y \to X \times X, y \mapsto (f(y),g(y))$. Notice that $E=h^{-1}(\Delta)$. Since $X$ is Hausdorff, $\Delta$ is closed, hence so is $E$.
Solution in the very particular case where $X$ has a topological vector space structure:

Let f-g=h which is continuous.
Your set is closed because it is $h^{-1}(0) $ which  the reciprocal image of closed set {0}.

Edit: I have added the first sentence because of a very appropriate remark of @PtF.