First-Class Functions

In this chapter, we'll dive deeper into Kotlin's support for first-class functions and how that support enables us to rethink how we write our code. You'll learn, in detail, how Kotlin functions are flexible, concise, and powerful by examining different types of functions, such as single expression functions and local functions. Finally, we'll explore how to leverage Kotlin features such as default parameter values, extension functions, and higher-order functions to write expressive, concise, and flexible code that reduces boilerplate and is more convenient to use.

The following topics will be covered in this chapter: