Question - Where should we use var and where val in Kotlin?
Answer -
In Kotlin, var is used where value is frequently changing. For example, while getting the location of the android device:
var integerVariable : Int? = null
In Kotlin, val is used where there is no change in value in the whole class. For example, when you want to set textview or button's text programmatically:
val stringVariables : String = "Button's Constant or final Text"