The Cartesian product is the set of all ordered pairs with from and from . Pair each element of with every element of ; there are pairs.
| Step | On , | |
|---|---|---|
| 1 | Fix the order of the factors. The first coordinate comes from the first set, so and are different sets. | pairs with , |
| 2 | Pair the first element of A with every element of B. Keep fixed and let run through . | |
| 3 | Repeat for each remaining element of A. One block of pairs for every element of . | |
| 4 | Collect the pairs and check the count. There must be pairs. | ; |