From: GOTO Kentaro Date: 2007-01-30T02:57:07+09:00 Subject: Re: cartesian product of arrays On 1/30/07, Trans wrote: > require 'facets/core/enumerable/op_pow' > > [1,2] ** [3,4,5] > => [[1, 3], [1, 4], [1, 5], [2, 3], [2, 4], [2, 5]] Confusing operand order... In set theory, e.g., http://mathworld.wolfram.com/Set.html the notation A^B, where A and B are arbitrary sets, is used to denote the set of maps from B to A. Then we get (a**b).size == (a.size)**(b.size) Gotoken