Multiple Variable Declarations in One Line? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

Multiple Variable Declarations in One Line?

How would you declare multiple variables in one line in Kotlin? Java: String x,y,z; Kotlin: ???

3rd Apr 2021, 9:46 PM
Szaky
Szaky - avatar
1 Answer
+ 1
val x:String; val y:String; etc Maybe this could work
4th Apr 2021, 8:35 AM
Solomon Simeon
Solomon Simeon - avatar