Skip to content

Instantly share code, notes, and snippets.


PatilShreyas/LazyDemo.kt Secret

Created Dec 29, 2020
What would you like to do?
val value by lazy {
println("Assigning a value")
fun main() {
println(value) // prints "Assigning a value 10"
println(value) // prints "10"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment