Prove that $\tau:(Y \times Z)^X \rightarrow Y^X \times Z^X$ is a homeomorphism if $X$ is hausdorff I have started learning about the Compact Open topology recently.

Prove that $\tau:(Y \times Z)^X \rightarrow Y^X \times Z^X$

I am completely baffled by this problem. Here $Y^X$ denotes continuous maps $X \rightarrow Y$
My attempts include trying to view the map as a pair of maps $f_1: (Y \times Z)^X \rightarrow Y^X$ and $f_1: (Y \times Z)^X \rightarrow Z^X$
Here the subbasis would be $W(K,U) =$ {$f \in Y^X | f(K) \subset U$} for a compact $K \subset X$ and $U$ open in $Y$
Now for $(Y \times Z)^X$ the subbasis would be {$ f \in (Y \times Z) | f(K = A \times B) \subset U = (V \times R)$ , I have written $K$ and $U$ in the form of basis elements (the standard form of product topology).
But from here I cannot proceed further and even if I do proceed further (possibly in the wrong direction) I don't make use of $X$ being Hausdorff
Hausdorffness seems to be a very useful property (although I don't know why) When dealing with Compact Open topologies but I don't know how to use it.
Edit: will $f:Y \times Z \rightarrow Y$ being continuous and that $f^X$ which we will define to be $f^X:(Z \times Y)^X \rightarrow Y^X$ being continuous help? I am quite sure that this function is continuous (although haven't tried anything)
Regards
 A: Your edit makes a good observation! The best first step is to verify functoriality (or at least part of it).
Lemma 1 Let $\alpha : A \to B$ be continuous, and let $X$ be any space. Then the map $\alpha^X : A^X \to B^X$ defined by $\alpha^X(f) = \alpha \circ f$ is continuous.
Proof. Let $K \subseteq X$ be compact and let $U \subseteq B$ be closed, so that $W(K,U) := \{g \in B^X : g(K) \subseteq U\}$ is a subbasic open set of $B^X$. Since $\alpha$ is continuous, $\alpha^{-1}(U)$ is open in $A$. Now I claim that the subbasic open set $$V(K,\alpha^{-1}(U)) := \{f \in A^X : f(K) \subseteq \alpha^{-1}(U)\}$$
is the preimage of $W(K,U)$ under $\alpha^X$. To see this, just note that
\begin{align*}
f \in (\alpha^X)^{-1}(W(K,U)) &\iff \alpha^X(f) \in W(K,U) \\
&\iff \alpha \circ f \in W(K,U) \\
&\iff (\alpha \circ f)(K) \subseteq U \\
&\iff \alpha(f(K)) \subseteq U \\
&\iff f(K) \subseteq \alpha^{-1}(U) \\
&\iff f \in V(K,\alpha^{-1}(U))
\end{align*}
Since $K$ and $U$ were arbitrary, this completes the proof. $\square$
Corollary $\tau = (\pi_1^X, \pi_2^X)$ is a bijective continuous map.
Proof. $\tau$ is bijective by the universal property of product spaces -- continuous maps $X \to Y \times Z$ correspond bijectively to pairs of continuous maps $X \to Y$ and $X \to Z$ by composing with the canonical projections $\pi_1 : Y \times Z \to Y$ and $\pi_2 : Y \times Z \to Z$. The continuity of $\tau$ again follows from the universal property -- its compositions with the projections $Y^X \times Z^X \to Y^X$ and $Y^X \times Z^X \to Z^X$ are the maps $\pi^X$ and $\pi^Y$, which Lemma 1 showed above are continuous. $\square$
And now the key fact:
Lemma 2 $\tau^{-1}$ is continuous.
Proof. Left to you (but comment if you're stuck!)
As far as I can tell, the Hausdorff assumption is unnecessary.
