October 2018
Intermediate to advanced
370 pages
9h 15m
English
The onEach function evaluates each element of the list and returns the original list afterward:
println("Get original list back and print square of each element")var newNumbers = numbers.onEach{ println(it * it)}
Read now
Unlock full access