KOTLIN AND ANDROID

KOTLIN  is a programing language that runs on JVM(java virtual machine). It is formed by the team of jetbrains.KOTLIN became very famous in android programing . If you’re interested in using Kotlin, it’s easy to get started because it works side by side with Java and C++ on Android. Starting with Android Studio 3.0, tooling support for Kotlin is bundled directly into Android Studio.

kotlin usage highlights

1: uber

2: coursera

3: atlassian

WHY KOTLIN

1:

Concise

Drastically reduce the amount of boilerplate code.

2:

Safe

Avoid entire classes of errors such as null pointer exceptions.

3:

Interoperable

Leverage existing libraries for the JVM, Android, and the browser.

4:

Tool-friendly

Choose any Java IDE or build from the command line.

EXAMPLES

package hello //Optional package header
fun main(args: Array<String>) //Package-level function, which takes an Array of strings as a parameter
{
println(“Hello World!”)
}
HERE you can notice that after println their is no semicolon (;) it is optional

Leave a Reply