Read More
Read now

Get Started with Kotlin on Android

Save

In this blog, we’re going to take a look at Kotlin, a new language in the JVM world, and some of its basic features, including classes, inheritance, conditional statements, and looping constructs.

Defining function in kotlin

Defining variables

Using when expression it’s more like switch case.

Using a for loop

Constructors

A class in Kotlin can have a primary constructor and one or more secondary constructors. The primary constructor is part of the class header  it goes after the class name (and optional type parameters).

Have you notice there no semicolon in sentences in Kotlin you don’t have to put the semicolon at the end of sentences. Null-safety is an important feature of the Kotlin language. It helps developers avoid NullPointerExceptions and improves the quality of their apps.

. . .

Leave a Comment

Your email address will not be published. Required fields are marked*


Be the first to comment.

css.php

Big thanks to Webkul and his team for helping get Opencart 3.0.3.7 release ready!

Deniel Kerr

Owner and Founder. Opencart

Talk to Sales
Start a Project

    Message Sent!

    If you have more details or questions, you can reply to the received confirmation email.

    Back to Home