Null and void




 In the initial days of Kotlin learning, I would just convert a java file to Kotlin using IDE option and then tweak to make it compile.

Most of this tweaking involved adding exclamation or question mark to variable names - for null checks. And I wasn’t sure, I will add ?, if that doesn’t work I will add  two exclamations. 

Then I learnt about lateinit keyword- how it allows you to define a variable which can be initialised later.

And now every so often my program crashes saying lateinit was never inited. :) :) 

You can't escape the null pointer exception!!

At least now I know what’s wrong and how to fix it. 

When we are on the subject ,let us talk about void.

This famous statue above is called Emptiness. It’s original artist is Albert Gyorgy! it's a bronze statue located at Lake Geneva.

I think this aptly describes the null, the void in all of us



Comments

Popular posts from this blog

ಹೂಗಳು

ಎಮ್ಮೆ

Not for nation