Elementary set theory problem and what's my misconcpetion? This is my proof for No.6, and tell me what's wrong.


*Let $f\in \left(\prod_{i\in I}A_i)\cup(\prod_{j\in J}B_j\right)$


$\Rightarrow$ $(f\in \prod_{i\in I}A_i)\lor(f\in \prod_{j\in J}B_j)$
$\Rightarrow$ $(f:I\to $ $\bigcup_{i\in I}A_i\;\land\ f(i)\in A_i\;\forall\;i\in I)$ $\lor$ $(f:J\to$ $\bigcup_{j\in J}B_j\;\land\; f(j)\in B_j\;\forall\;j\in J)$
$\Rightarrow$ $(f: I\times\bigcup_{i\in I}A_i$ $\lor $ $f: J\times\bigcup_{j\in J}B_j)$$\land$
$(f: I\times\bigcup_{i\in I}A_i$$\lor$$f(j)\in B_j\;\forall\;j\in J)$$\land$
$(f(i)\in A_i\;\forall\;i\in I$$\lor$$f:J\to$ $\bigcup_{j\in J}B_j)$$\land$$(f(i)\in A_i\;\forall\;i\in I$$\lor$$f(j)\in B_j\;\forall\;j\in J)$
Here is where I have been jammed in.
I thought that the first bracket at the last line like this
$(f: \left(I\cup J\right)$$\times$$\bigcup_{i\in \left(I\cup J\right)}\left(A_i\cup B_j\right))$
But I couldn't deal with the remained brackets.
then 
how can I deal with those brackets to make them like
$\prod_{(i,j)\in I\times J}\left(A_i\cup B_j\right)$


  
*Let $\{A_i\}_{i\in I}$ and $\{B_j\}_{j\in J}$ be families of classes. Prove that $$\left(\prod_{i\in I}A_i\right)\cup\left(\prod_{j\in J}B_j\right)=\prod_{(i,j)\in I\times J}\left(A_i\cup B_j\right)\;.$$
  

 A: It would be easier, not to mention easier to read, if you used more words and didn’t try to do everything symbolically. The real problem, however, is that the result is false. Let $I=J=\{0,1\}$, $A_0=\{0\}$, $A_1=\{1\}$, $B_0=\{2\}$, and $B_1=\{3\}$. Then
$$\prod_{i\in I}A_i=\{0\}\times\{1\}=\{\langle 0,1\rangle\}$$
and
$$\prod_{j\in J}B_j=\{2\}\times\{3\}=\{\langle 2,3\rangle\}\;,$$
so
$$\left(\prod_{i\in I}A_i\right)\cup\left(\prod_{j\in J}B_j\right)=\{\langle 0,1\rangle,\langle 2,3\rangle\}\;,\tag{1}$$
but
$$\prod_{\langle i,j\rangle\in I\times J}(A_i\cup B_j)=\{0,2\}\times\{0,3\}\times\{1,2\}\times\{1,3\}\;.\tag{2}$$
The set in $(1)$ has two members, each of which is an ordered pair; the set in $(2)$ has $16$ members, each of which is an ordered $4$-tuple. Clearly the sets are not equal.
Is it possible that your source is using the very old-fashioned notation in which $\prod_{i\in I}A_i$ means what we nowadays write $\bigcap_{i\in I}A_i$, the intersection of the sets $A_i$? Because under that interpretation the result is true.
