I need to generate every possible combination of the the values in an array.
For example, if...
$array = Array("A", "B", "C");
I want to be able to do something like
which would output
 => "ABC"
 => "ACB"
 => "BAC"
 => "BCA"
 => "CAB"
 => "CBA"
I really have no idea where to begin. The best lead I can think of is that
there are going to be n! elements in the output array, where n is the size of
the input array.
Any help would be greatly appreciated.
Think not those faithful who praise all thy words and actions, but those who
kindly reprove thy faults.
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php