Book Image

Programming Kotlin

Book Image

Programming Kotlin

Overview of this book

Quickly learn the fundamentals of the Kotlin language and see it in action on the web. Easy to follow and covering the full set of programming features, this book will get you fluent in Kotlin for Android.
Table of Contents (20 chapters)
Programming Kotlin
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Customer Feedback
Preface

Chapter 5. Higher Order Functions and Functional Programming

In the previous chapter, we introduced Kotlin's support for functions and the various features we can use while writing functions. In this chapter, we continue on that theme by discussing higher order functions and how we can use them to write cleaner and more expressive code.

In this chapter, we will cover:

  • Higher order functions and closures

  • Anonymous functions

  • Function references

  • Functional programming idioms

  • Custom DSLs