Medium
var chaine : String? = null
chaine?.let { println("string is $chaine") } ?: run { println("string was null. Setting the value to:")
chaine = "Kotlin"}
println(chaine)
What does the console show?
Author: W3D TeamStatus: PublishedQuestion passed 509 times
Edit
1
Community EvaluationsNo one has reviewed this question yet, be the first!
Similar QuestionsMore questions about Kotlin