Hello world application in Kotlin

Kotlin Hello World Application

To get started open your editor and type the snippet of code below

fun main() {
    println("Hello, World!")
}

in kotlin main is the entry point function of an application

fun keyword is used for declaring functions it acts like function does in JavaScript.

Compile your application into jar
kotlinc hello.kt -include-runtime -d hello.jar

Execute your application
java -jar hello.jar

If everything went well you should see "Hello World" output from your terminal

Comments

Popular posts from this blog

FlappingBird Postmortem (JS13K)

JavaScript introduction to variables

FlappingBird JS13K Games

How to target all elements of a given class name in JavaScript

Zedplug will be decommissioned on November 30th