it'd be good to know the reason why you have to do...
# getting-started
k
it'd be good to know the reason why you have to do
forEach(Item::call)
, by the way.
forEach
takes a
(T) -> Unit
as its argument. You can do
foo.forEach { it.call() }
, but
foo.forEach({ it.call() })
is also a valid syntax, since you're passing the function as the 1 argument there