Introduction to Kotlin

Learn Kotlin, a modern language for the JVM
4.2 (24 ratings)
Instead of using a simple lifetime average, Udemy calculates a
course's star rating by considering a number of different factors
such as the number of ratings, the age of ratings, and the
likelihood of fraudulent ratings.
110 students enrolled
70% off
Take This Course
  • Lectures 48
  • Length 4.5 hours
  • Skill Level All Levels
  • Languages English
  • Includes Lifetime access
    30 day money back guarantee!
    Available on iOS and Android
    Certificate of Completion
Wishlisted Wishlist

How taking a course works


Find online courses made by experts from around the world.


Take your courses with you and learn anywhere, anytime.


Learn and practice real-world skills and achieve your goals.

About This Course

Published 1/2016 English

Course Description

This is a course on the Kotlin programming language. This course is designed for people already familiar with Java who are looking for a more modern, expressive and powerful language for the JVM.

In this course, you will learn about:

  • How to install and run Kotlin and why toolability matters
  • Type inference and how it can save you a lot of time
  • Smart control flow structures that let you write more succinctly
  • Mutability options (val and var), what they mean and how to use them
  • Nullability guarantees and how they make your code more safe
  • The power of functional literals (nested functions and lambdas)
  • Powerful built-in delegation functionality
  • How to leverage Kotlin's collection operations to process data sets efficiently

... and a lot more!

This course is completely live-demo based. All the lectures are examples of real code being edited and executed using the IntelliJ IDEA Community Edition IDE.

What are the requirements?

  • A good knowledge of Java is required

What am I going to get from this course?

  • Solve problems in Kotlin
  • Understand Kotlin's advantages over Java
  • Effectively leverage Kotlin's null safety and mutability guarantees
  • Speed up work with collection using Kotlin's collection operationrs
  • Have fun with a new JVM language!

Who is the target audience?

  • Java developers looking for a better programming language
  • Developers looking for interesting language design ideas

What you get with this course?

Not for you? No problem.
30 day money back guarantee.

Forever yours.
Lifetime access.

Learn on the go.
Desktop, iOS and Android.

Get rewarded.
Certificate of completion.


Section 1: Introduction to Kotlin

A brief overview of why Kotlin is so good.


A little note about the options available for downloading and installing Kotlin.


Let's set up the IDE and run our first Kotlin program.

Section 2: Types and Variables

Learn about the difference between val and var. Also: there is no new and no semicolons.


Thanks to type deduction, most variable type decorations are not necessary. Woo-hoo!


Ranges of values. Self-explanatory, right?


A look at how arrays are represented and used in Kotlin.


Strings aren't complicated, but interpolation makes them more powerful.

Section 3: Control Flow

Kotlin provides powerful support for dealing with nullability. Lean everything about ?, ?., ?: and !!


Yer olde if is an expression that can return values and can appear in interpolated strings.


Why should the IDE check if you are risking an NPE, if the compiler can do it just as well? This awesome compiler feature also takes care of type conversions and more.


This ain't your father's for loop!


Kotlin's powerful alternative to Java's switch.

Section 4: Functions

Kotlin has functions which are not inside any class. What is this, C++?!?


Kotlin supports default argument values and calls with named arguments.


Call a function with any number of arguments, comma-separated-like.


Functions within functions.


Explains how functions such as downTo are implemented.

Section 5: Lambda Functions

Yay, lambdas! Oh, wait, Java has lambdas too? Yeah, but not like these!


Functions taking functions, but why?


Define the context of the function's operation. Advanced topic!


Give a class a magic method called invoke and call it like a function (a.k.a. functor).

Section 6: Classes

What, no fields? With Kotlin, forget about fields and getter/setter hell: properties take care of it all!


Give any type additional functionality.


Primary constructors provide an epic level of succinctness. But if you need to do more than initialize some fields, init block to the rescue!


You can override the implementation of a property in an external class. But why?!?


Simple, yet powerful, data classes auto-implement the basic scaffolding for you. Don't worry, you can override anything you don't like!


Kotlin lets you make Singletons with ease. It doesn't have static functions, but companion objects are a close alternative.


Kotlin doesn't have statics. But you can still get them, in a way.


Learn about the override keyword, base call disambiguation, opening types and more.


Interfaces... can contain properties as well as functions.


The Decorator pattern is essentially built-in in Kotlin.

Section 7: Collection Operations

A discussion of Kotlin collection support and why it rocks.


Let's dig into kotlin-runtime.jar and find all the classes related to collection operations as well as sequences. We'll also learn how to make sequence generators: a useful feature that we'll use throughout this entire section.


Counting how many elements fit a predicate.


Mapping each element to something else.


Compressing a sequence to a single value.


Keeping elements satisfying (or not) a particular predicate and throwing all others away.


Splitting a sequence based on a criterion.


Grouping elements by a particular key.


Sorting a data set by one or more of its properties.


Operations which try to access an individual element of the collection.


Operations on algebraic sets.


A summary of all the collection operations we've discussed in this section of the course.

Section 8: Odds & Ends

Yes, enumerations, with abstract functions and whatnot.


Kotlin has no checked exceptions. But try-catch is an expression.


But only standard operators, none of that F#-inspired operator <#%$> magic.


A look at how function types with receivers, together with lambda expressions, can help us make Groovy-style builders.

Students Who Viewed This Course Also Viewed

  • Loading
  • Loading
  • Loading

Instructor Biography

Dmitri Nesteruk, Quantitative Finance Professional

Dmitri Nesteruk is a developer, speaker and podcaster. His interests lie in software development and integration practices in the areas of computation, quantitative finance and algorithmic trading. His technological interests include C#, F# and C++ programming as well high-performance computing using technologies such as CUDA. He has been a C# MVP since 2009.

Dmitri is a graduate of University of Southampton (B.Sc. Computer Science) where he currently holds a position as a Visiting Researcher. He is also an instructor on an online intro-level Quantitative Finance course, and has also made online video courses on CUDA, MATLAB, D, the Boost libraries and other topics.

Ready to start learning?
Take This Course