13 Reasons why I love Kotlin

Rashi Karanpuria
AndroidPub

--

Since Android Studio 3, all my new projects are in pure Kotlin! I make sure I am somehow able to use Kotlin even if it involves explaining to the client, why they would rather want to have their app in Kotlin than in Java. One of the reasons why the clients don’t want to use Kotlin is because AS 3 is not a stable build right now. By the way, there is a Kotlin support plugin for AS 2, which can be used in place. Other reasons are vague like I’d rather have Java, it is standard, native apps are in Java, stuff that I can not and do not want to argue with.

I started learning Kotlin just as a fun hobby back when Google announced official support. I wanted to know what was all the hype about. I so wish I had started sooner.

You have to try Kotlin and if you haven't already, you are missing out on a lot of great things. Some of the major reasons why I’d rather stick to Kotlin, in order of priority:

1. No null checks anymore

Kotlin programming language aims at eliminating the perils of null references from code, which is often called The Billion Dollar Mistake. All those if(x != null) and try catch blocks gone! And so many null pointer exceptions also gone! Who does not want that? Kotlin addresses null exceptions at compile time which automatically handles all the NPE’s that used to occur at compile time.

--

--

Rashi Karanpuria
AndroidPub

Software Engineer @ Google | Author of Kotlin Programming Cookbook | www.rashikaranpuria.com