unfold
fun <E> E.unfold(extractor: (E) -> <Error class: unknown class><E>): <Error class: unknown class><E>
The opposite of fold.
Receiver
The starting element to unfold.
Return
A sequence of E generated by unfolding on each element provided by the extractor function.
Parameters
extractor
A function that provides a sequence of elements given a specific element of the same type.
See also
fold
.