When a lambda is passed to a function as the only or last argument, enclosing it in parentheses is optional. Let's go back to our click listener example. We could have also written it like this:
button.setOnClickListener { v -> println("Clicked on: $v") }
This feature enhances readability and is particularly useful if you are creating a DSL (Domain-Specific Language) with Kotlin.