Update kotlin.html.markdown

Improve variables explanation
This commit is contained in:
Andrew 2023-10-31 19:29:19 +10:30 committed by GitHub
parent 088f41898a
commit f5f86b3df0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -26,7 +26,7 @@ any parameters.
*/
fun main(args: Array<String>) {
/*
Declaring values is done using either "var" or "val".
Declaring variables is done using either "var" or "val".
"val" declarations cannot be reassigned, whereas "vars" can.
*/
val fooVal = 10 // we cannot later reassign fooVal to something else