# Understanding Kotlin's let(), also(), run(), and apply()

DevFeed: [Understanding Kotlin's let(), also(), run(), and apply()](<https://devfeed.tech/articles/understanding-kotlin-s-let-also-run-and-apply-25044.md>)

Original publisher: [Read original article](<https://typealias.com/guides/understanding-let-also-run-apply/>)

Author: author@typealias.com (Dave Leeds)

Published: 2017-09-08T00:00:00Z

Content type: tutorial

Language: en

Sources: [Dave Leeds on Kotlin - typealias.com](<https://devfeed.tech/sources/dave-leeds-on-kotlin-typealias-com.md>)

Topics: [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [Programming](<https://devfeed.tech/topics/programming.md>), [Library](<https://devfeed.tech/topics/library.md>), [Code](<https://devfeed.tech/topics/code.md>)

Tags: [extension-function](<https://devfeed.tech/tags/extension-function.md>), [function](<https://devfeed.tech/tags/function.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [programming](<https://devfeed.tech/tags/programming.md>), [scope-functions](<https://devfeed.tech/tags/scope-functions.md>), [standard-library](<https://devfeed.tech/tags/standard-library.md>)

## AI overview

A guide to Kotlin's let(), also(), run(), and apply() scope functions. It explains their shared characteristics and distinguishes them by code-block context and return value.

## Source excerpt

Kotlin's standard library includes some often-used scope functions that are so abstract that even those who have been programming in Kotlin for a while can have a hard time keeping them straight. In this guide, we're going to clarify four of these scope functions in particular - let(), also(), run(), and apply(). By the end of this guide, you'll have a framework for understanding them and should have a good idea of which one is most applicable in different scenarios.