Kotlin – first steps –

What is Kotlin?

From the jetbrains blog :

Kotlin is a pragmatic programming language for JVM and Android that combines OO and functional features and is focused on interoperability, safety, clarity and tooling support.

Being a general-purpose language, Kotlin works everywhere where Java works: server-side applications, mobile applications (Android), desktop applications. It works with all major tools and services…

I want to try this new programming language for two reasons:

  • I want to study something new
  • I was born as c++ developer and, for me, Kotlin is very simple to read and to understand, so i can use this language where java is used.

The number of github Kotlin projects is esponenctially increased in the last few years, so this is another good reason to start to learn this programming language.

kotlinadoption

 

Well, after this introduction about “why” i want to learn Kotlin, let’s start with something interesting for the developer.

Like every fist step into new programming language I started from “HelloWorld”:

fun main(args: Array<String>){
    println("Hello World");
}

These two lines of code show how to create a function (fun), how to declare the parameters accepted by the function and hoe to write something on the standard output.

For me is very simple and intuitive.

I want to go deeper into the Kotlin world!

 

 

 

Advertisements

One thought on “Kotlin – first steps –

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s