Subject: | Permutation over multiple input lists |
I'm looking for a way to generate permutations of multiple input lists. Here's an example of what I'm looking for with two lists:
my @kids = qw(bob sam kelly sally);
my @toys = qw(top ball horn bell puppet);
permute(\@kids, \@toys);
---
bob top
bob ball
...
sam top
sam ball
...
A few searches show this is a desired feature in many different languages, but I can't find anything on CPAN that does this.