1.

How does string interpolation work in Kotlin?

Answer»

STRING INTERPOLATION is a variable substitution having its value INSIDE a string. In Kotlin, the $ character is used for interpolating a variable, and the ${} is used to interpolate an EXPRESSION. Kotlin allows users the liberty of accessing variables and expressions directly from the string literals, thus ELIMINATING the need for concatenation.



Discussion

No Comment Found