JetBrains, introduced Kotlin in 2016, is a cutting-edge programming language. It is an open-source programming language.
Its popularity is because of its compatibility with Java. Kotlin is an object-oriented language that is better than Java but can still work with Java code and libraries.
The critical question arises why do we have to use Kotlin when there are so many different languages? The answer to this question is the many advantages Kotlin offers us.
Following are the advantages of using Kotlin:
Let’s try to print “Hello World!” in Kotlin.
fun main(args : Array<String>){println("Hello World!")}
main
function necessary to start a Kotlin program. The main
function is the first thing the Kotlin compiler will run.println
function prints everything that is written inside. In this program, it will print “Hello World!”.Free Resources