Things to Know Before Learning Kotlin
Why Kotlin was Created?
Kotlin was created by JetBrains, a company renowned for creating development tools for professionals.
Back in August, 2011, JetBrains published a blog post, Why JetBrains needs Kotlin, explaining reasons behind the creation of Kotlin. Here are the main points:
- To increase their (JetBrains) productivity
Back then, JetBrains team were writing all of their IntelliJ-based IDEs almost entirely in Java. It took a lot of time to compile with javac. They wanted to increase productivity by switching to a more expressive language.
- To drive sales of IntelliJ IDEA
They wanted the enterprise development frameworks and tools for Kotlin to be the part of IntelliJ IDEA Ultimate (commercial version) thereby increasing its sales.
- Drive company's business by keeping trust
JetBrains is trusted by a lot of professional developers. They wanted to drive company's business as well as attract more people to their approach of developing tools by increasing community awareness of JetBrains and maintaining the trust.
Features of Kotlin
Kotlin is a statically typed language. Here are some of the important features of Kotlin:
- Open source
Kotlin is distributed under Apache License, Version 2.0. The Kompiler (Kotlin compiler), IntelliJ IDEA plugin, enhancements to basic Java libraries and build tools all are open source.
- Interoperable with Java and Android
It is 100% interoperable with Java and Android. This means all your current Java/Android code works seamlessly with Kotlin. For more information, visit: Mixing Java and Kotlin in One Project.
- Concise and Expressive
Rough estimation indicates that, using Kotlin allows you to cut off the lines of code by approximately 40% (compared to Java).
Expressive means, it's easy to write code that both humans and compilers can understand easily.
- Easy to Learn
Kotlin is developed by JetBrains, a company renowned for creating development tools for professionals. No wonder, it is tool-friendly.
You can choose any Java IDE to run Kotlin or build it from the command line.
It is aimed at removing dangers of null references from the code (a big headache in Java). Also, it is statically typed which gives ability to catch more errors at run-time (type safe).