ForEach

This iterates over the collection and calls the given action function on each item:

val numbers = listOf(1, 2, 3, 4, 5)
numbers.forEach { n -> println(n) }
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.224.43.85