Intermediate Kotlin
Q45 / 100

What does the inline keyword do for a higher-order function?

Correct! Well done.

Incorrect.

The correct answer is A) Inlines the function body into the call site, avoiding lambda object allocation

A

Correct Answer

Inlines the function body into the call site, avoiding lambda object allocation

Explanation

Inline functions copy their body (and the lambda bodies) to each call site at compile time, eliminating the overhead of lambda object creation and virtual dispatch.

Progress
45/100