Kotlin - Data Types
Identify the error in this Kotlin code snippet:
var greeting = "Hi" greeting[0] = 'B' println(greeting)
var greeting = "Hi" greeting[0] = 'B' println(greeting)
greeting[0] = 'B' tries to change a character, which is invalid.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions