Why you should switch to Kotlin?


Sorry guys, I have been underground for a while and frankly speaking I wasn’t doing anything fancy. :[ But now I am back and meanwhile, I have learned MVP, Android Architecture Components, and Kotlin 🧡.

I have made a switch to Kotlin in all of my projects. And that’s the reason that all the upcoming articles on The Engineers Cafe will be written in Kotlin.

I am writing this article to put some light on the benefits of Kotlin, help you in getting started with it and also motivate your friends working in Android to do the same.

What is Kotlin?

According to Wikipedia,

Kotlin is a statically typed programming language that runs on the Java virtual machine and also can be compiled to JavaScript source code or use the LLVM compiler infrastructure.

It was developed by the JetBrains team (Also the developer of the Android Studio). Kotlin made its first appearance in 2011. The name “Kotlin” comes from Kotlin Island located near St. Petersburg.

Kotlin generates JVM bytecode and JavaScript source code and hence can run on any OS supporting JVM or JavaScript Interpreter.
It is interoperable with Java and you can use it side by side in your Android project.

Why switch to Kotlin?

There are many reasons to shift to Kotlin. I am listing the ones which I think are the most important and convinced me to switch to Kotlin for Android development 😎

  • It is officially supported by Google for Android development and comes directly included with Android Studio 3.0 and above. Google declared first-class support for Kotlin on Android at Google I/O 2017.
  • Kotlin is interoperable with Java and hence you can gradually include it in the project.
  • Extension functions are bliss.
  • No semicolons, no new keywords, and no findViewByIds 😛.
  • No more famous Null Pointer Exceptions.
  • Less boilerplate code.
  • A very positive feedback from the community along with the increasing adoption.
  • Lots of tutorials and quality courses already available.
  • It is open source.

If you are an experienced Android developer but a newbie to Kotlin, I recommend going through the Kotlin documentation. It would be a good starting point and reading books listed below can also help you to get expertise over the Kotlin programming language.

You may also want to have a look at this free boot camp course on Udacity by Google.

Also, I recommend following all the Google Developer Experts for Kotlin on Social Media. These experts do a great job of sharing quality content with the community. This content can help you a lot in increasing your knowledge and staying up to date with the latest trends in Android programming.

P.S. All the upcoming Android Tutorials on The Engineers Cafe will be written in Kotlin. If you haven’t made your mind to switch to Kotlin, this may give you some extra motivation 😬

Do tell me your views in the comments section and if you are a JAVA fan, we have a lot to discuss :]

About the author

Mehul Kanzariya

Passionate about Android Development and all things tech.

Recommended Host

Siteground hosting Covid19 offers

Top Posts