cumulative
inline fun <T, R> Iterator<T>.cumulative(initial: R, crossinline operation: (R, T) -> R): Iterator<R>(source)
Generic cumulative operation on iterator.
Parameters
T
the type of initial iterable.
R
the type of resulting iterable.
initial
lazy evaluated.
inline fun <T, R> Iterable<T>.cumulative(initial: R, crossinline operation: (R, T) -> R): Iterable<R>(source)