what is the use of extension functions in Kotlin?
Answer / Pitamber Arya
Extension functions allow you to add new functionality to existing classes without modifying the original source code. They are defined outside the class they extend and can be used with a dot notation, just like instance methods. This feature makes it possible to extend existing libraries or third-party libraries in Kotlin.
| Is This Answer Correct ? | 0 Yes | 0 No |
Define Kotlin Programming Language?
What is kotlin’s null safety?
Does Kotlin support primitive Datatypes?
What is the purpose of creating kotlin?
Mention few features that Kotlin provides but not java ?
Give an example of high order functions?
Which is the default modifier for a method, variable, class?
How to write multiline string in kotlin?
Is it possible to migrate the code from Java to Kotlin?
Does Kotlin allow macros?
List the Basic data types of Kotlin?
Why is kotlin preferred over java?