Topology closed sets in products of spaces I got stuck at question 3.7.1 in Bert Mendelson's introduction to Topology.

Prove that a subset $F$ of $X = \prod_{i=1}^nX_i$ is closed if and only if F is an intersection of sets, each of which is a finite union of sets of the form $F_1 \times F_2 \times ... \times F_n$, where each $F_i$ is a closed subset of $X_i$. Formulate the corresponding statement in an arbitrary product of topological spaces.

I started with 'F is an intersection ... closed subset of $X_i$' and tried to prove that F must then be closed. Now by this presupposition we can write $F$ as $F = \bigcap_{\alpha \in I} \bigcup_{i=1}^m C_{1\alpha i } \times C_{2\alpha i } \times ...\times C_{n\alpha i } $. Since we need to prove that the complement of F is open, I tried to take the complement of F. 
This way I nearly arrive at the first desired implication; using DeMorgan's rules I obtain 
$F = \bigcup_{\alpha \in I} \bigcap_{i=1}^m (C_{1\alpha i } \times C_{2\alpha i } \times ...\times C_{n\alpha i })^C $. Now I suspect $C_{1\alpha i } \times C_{2\alpha i } \times ...\times C_{n\alpha i }$ is a closed subset of $X$ for each $\alpha,i$ from which it follows that $F$ is open by the definition of the topology of a product of spaces. However I do not know how to prove this; this isn't true in general.
Does anyone know how to prove this? Or is there something wrong with my approach? After I understand the first implication I'm hoping to be able to do the converse myself.
Please let me know if parts of my question or notation are unclear. Thanks in advance for any help!
 A: In any product space $\prod_{i\in I} X_i$ all open sets are unions of (finite intersections of "elementary open sets"), where an "elementary open set" is of the form $p_j^{-1}[O]$ where $j \in I$ and $p_i: \prod_{i\in I} X_i \to X_j$ is the projection onto the $j$-th space $X_j$, and $O$ is open in $X_j$. We can see these as $$p_j^{-1}[O] = \prod_{i\in I} O_i$$ where $O_i =X_i$ for all $i \neq j$ and $O_j =O$ sometimes denoted (by abuse of notation ) as $$\prod_{i\neq j} X_i \times O$$
The complement of an elementary open set I'll call an elementary closed set, so this is of a similar form with a closed set at the $j$-th coordinate:
$$p_j^{-1}[O]^{\complement} = p_j^{-1}[X\setminus O] = \prod_{i\in I} F_i \text{ with } F_i = X_i \text{ for } i \neq j \text{ and } F_j=X\setminus O =\\
\prod_{i \neq j} X_i \times F \text{ where } F = X\setminus O \text{ is closed}$$
By de Morgan we then have that every closed set is the intersection of (finite unions of "elementary closed sets"), which is the form you are looking for.
