On the Wikipedia page of "product topology", they define the Cartesian product of the topological spaces $Xi$ as $X= \Pi_{i\in I} X_i$
Now, in class, my professor defined $\Pi_{i\in I} X_i = \{x_i: I \rightarrow \cup_{i \in I} X_i, x_i \in X_i, \forall i \in I\}$
Now I am trying to understand that last equality given my professor. I don't quite understand it and I don't understand what it bring to the original definition of the cartesan product of sets.