Kotlin HashSet runningReduce()
Syntax & Examples
Syntax of HashSet.runningReduce()
The syntax of HashSet.runningReduce() extension function is:
fun <S, T : S> Iterable<T>.runningReduce( operation: (acc: S, T) -> S ): List<S>
This runningReduce() 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 the first element of this collection.