Permutator
A Permutator iterates over all possible permutations of the given array of elements.
- Full name:
\Permutator
Properties
list
Constructs a new Permutator.
done
left
Methods
__construct
Parameters:
Parameter | Type | Description |
---|---|---|
$list |
mixed |
hasNext
Returns true if there is another permutation.
Return Value:
true if there is another permutation, false if not.
next
Gets the next permutation. Call hasNext() to ensure there is another one first.
Return Value:
the next permutation.
Automatically generated on 2025-03-18