asSequence

fun <T, D : Dimension> MultiArray<T, D>.asSequence(): Sequence<T>

Creates a Sequence instance that wraps the original collection returning its elements when being iterated.