Kotlin HashSet runningFold()
Syntax & Examples
Syntax of HashSet.runningFold()
The syntax of HashSet.runningFold() extension function is:
fun <T, R> Iterable<T>.runningFold( initial: R, operation: (acc: R, T) -> R ): List<R>
This runningFold() extension function of HashSet returns a list containing successive accumulation values generated by applying operation from left to right to each element and current accumulator value that starts with initial value.