Kotlin - Variables and Type System
What will be the output of this Kotlin code?
var x = 3 x = x + 4 println(x)
var x = 3 x = x + 4 println(x)
x is 3. Then x = x + 4 updates x to 3 + 4 = 7.println(x) prints the current value of x, which is 7.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions