This is an excerpt from Manning's book The Joy of Kotlin. Login to get full access to this book.
Up to now, you’ve been using named functions. Often, you won’t define names for functions; you’ll use them as anonymous functions. Let’s look at an example. Instead of writing