that runs on the Java virtual machine ▸ Can also be compiled to other language such as javascript, android & native ▸ Publicly Unveiled July 2011 after 1 year of development ▸ Relaxes Java’s restrictions, allow functional programming style
of boilerplate code ▸ Safe Avoid entire classes of errors such as null pointer exceptions ▸ Interoperable Leverage existing libraries for the JVM and the browser. Can work with existing java code in Android ▸ Introduce new approach Coroutines, Ktor architecture
The ecosystem (library, framework, doc, googleable/stackoverflow) ▸ Your team ▸ Your code, your utility class & lib ▸ How long do we need to be back to the same productivity, and more! (how long must we take a hit on productivity)
(after 1 year of development) ▸ February 15, 2016 - Kotlin v1.0 was released ▸ Google I/O 2017 - Google announced first-class support for Kotlin on Android (wizzard, kotlinx.android.synthetic, gradle, etc) ▸ September 14, 2018 - Koin 1.0.0 unleashed ▸ October 29, 2018 - Kotlin coroutine 1.0 released ▸ November 19, 2018 - Ktor 1.0 released
▹ Set listener / anonymous class ▹ Data class ▹ At least 20% less code vs Java ▸ Tools ▹ More tools are built for kotlin ▹ Popular library now support kotlin ▸ New Arsenal ▹ Kotlin coroutine
▸ Syntax - Minimum ▸ Gotchas - Immediate ▸ Common & Best practices - Immediate The goals is to learn the essential to make it work. Supplement it with our experience. While adding new knowledge over time.
Interoperability with java ▹ Can be used parallel with java in android project ▹ Have simpler syntax ▹ Can mix between OOP and Functional Programming ▹ Design specially to handle null safety ▸ IDE Support ▹ Java to Kotlin converter ▹ Kotlin bytecode decompiler
You can change the variable later on ▹ val is immutable variable. You can’t change the variable but you can still manipulate the content ▸ Null Safety ▹ Kotlin's type system is aimed at eliminating the danger of null references from code ▹ Type system distinguishes between references that can hold null (nullable references) and those that can not (non-null references) ▹ The goals is to make your code cleaner and safe from Null cases
to accustomed to this type of syntax (even some of you would protest a lot) ▹ Reverse notation ▹ Infer type ▹ The curly braces (Scope) ▹ Etc ▸ Take it slowly, you’ll get used to it
class citizen. ▹ That means that they can be stored in variables and data structures, passed as arguments to and returned from other higher-order functions. You can operate with functions in any way that is possible for other non-function values. ▸ That means we work a lot with anonymous function/ Lambda expression ▹ Lambda expressions are 'function literals', i.e. functions that are not declared, but passed immediately as an expression val sum = { x: Int, y: Int -> x + y }