CROSS
Monday, March 07, 2011
2:52 PM
Suppose s1 and s2 are bags. Then 
foo = CROSS s1,s2 
contains all combinations of s1 and s2 taken one at a time.
Example: if foo contains
(1,2)
(3,4)
and bar contains
(amy,fred)
(george, jack)
then CROSS foo,bar contains
(1,2,amy,fred)
(1,2,george,jack)
(3,4,amy,fred)
(3,4,george,jack)