I hope someone will read this long question to the end, I'm getting really desperate.

Here's what I have to prove:
Let \psi: \mathbb{N}^d \times B^k \rightarrow B be defined as follows:
\alpha=(n_1, \ldots, n_d, f_1, \ldots, f_k)
\psi(\alpha)=(n_1, \ldots, n_d, f_1(0), f_2(0), \ldots, f_k(0), f_1(1), \ldots, f_k(1), \ldots),
where B is the Polish set B=\mathbb{N}^{\mathbb{N}} with product topology and every \mathbb{N} has discrete topology.
Show that \psi is a homeomorphism.

Injectivity and surjectivity is easy, continuity isn't.

Here are the facts:
f:B \rightarrow B is continuous if \forall x \in B and \forall \sigma \subset f(x) \exists \tau \subset x such that \tau \subset y \Rightarrow \sigma \subset f(y).

f:X\rightarrow \Pi Y_i is continuous if and only if \pi_i \circ f is continuous, for all i.

Here's what I got, after huge online help:
Let \phi=\psi^{-1} be the inverse.
\phi: B \rightarrow \mathbb{N}^d \times B^k is continuous if p \circ \phi and q \circ \phi are continuous, where
p: \mathbb{N}^d \times B^k \rightarrow \mathbb{N}^d takes (x, y) \in \mathbb{N}^d \times B^k  to x\in \mathbb{N}^d.
q: \mathbb{N}^d \times B^k \rightarrow B^k, akes (x, y) \in \mathbb{N}^d \times B^k  to y\in B^k.

Since \mathbb{N}^d and B^k are also products, we can say that \phi is continuous if p_i \circ \phi, i=1, \ldots, d and q_j \circ \phi, j=1,\ldots, k are continuous.
p_i sends (x, y) to the i-th coordinate of the \mathbb{N}^dpart, and q_j sends (x, y) to the j-th coordinate of the B^k part.

Now it's easy to prove that the inverse is continuous.

The question is: what do I do about \psi?

Please advise.
Thank you!