Kotlin Tutorial
Course Contents
Kotlin Fundamentals
- Kotlin Introduction
- Installing Kotlin
- Kotlin Get Started (Hello World)
- How Kotlin Works: The JVM and Interop with Java
- Compiling and Running Kotlin
- Kotlin Scripts vs Programs
Kotlin Basics
- Variables: val and var
- Basic Types
- Type Inference
- Nullable Types and the Safe Call Operator
- String Templates
- Type Conversion
Control Flow
- if as an Expression
- when Expressions
- for Loops and Ranges
- while and do-while Loops
- break, continue, and Labels
Null Safety
- Null Safety Explained
- The Safe Call Operator (?.)
- The Elvis Operator (?:)
- The Not-Null Assertion (!!)
- Safe Casts and let
Functions
- Functions in Kotlin
- Default and Named Arguments
- Single-Expression Functions
- Lambda Expressions
- Higher-Order Functions
- Extension Functions
- vararg Parameters
Classes and Objects
- Classes in Kotlin
- Primary and Secondary Constructors
- Properties and Fields
- Data Classes
- Inheritance and open Classes
- Interfaces
- Abstract Classes
Object-Oriented Features
- The object Keyword and Singletons
- Companion Objects
- Sealed Classes and Interfaces
- Enum Classes
- Visibility Modifiers
- Nested and Inner Classes
Collections
Functional Collection Operations
- map, filter, and forEach
- reduce and fold
- sortedBy and groupBy
- Sequences and Lazy Evaluation
- Chaining Collection Operations
Generics
Error Handling
Coroutines
- Coroutines Introduction
- suspend Functions
- launch and async
- Coroutine Scope and Dispatchers
- Structured Concurrency
Delegation and Advanced Features
- Property Delegation
- lazy Delegated Properties
- Class Delegation
- Operator Overloading
- Destructuring Declarations
- Inline Functions
Kotlin in Practice
- Reading and Writing Files
- Working with JSON
- Kotlin and Java Interop
- Unit Testing with kotlin.test
- Scope Functions: let, run, with, apply, also
