Question: what is extension in kotlin?
Answer: Extensions. Kotlin provides the ability to extend a class with new functionality without having to inherit from the class or use design patterns such as Decorator. ... For example, you can write new functions for a class from a third-party library that you can't modify.