Create home screen Part 4 | Taking advantage of Kotlin - Android Kotlin Tutorial

Опубликовано: 14 Март 2026
на канале: Let's Finish this APP - Kotlin and Swift Tutorials
764
10

Kotlin is a statically-typed programming language that runs on the Java virtual machine and also can be compiled to JavaScript source code or use the LLVM compiler infrastructure

Taking Advantage of Kotlin
1. Taking advantage of Android studio i.e implementing suggestion provided by IDE.

2. Uses Kotlin standard Library function ie. any() and firstOrNull() to traverse fragment manager list.

3. Reduce number of code lines if we compare code which is created from Java to Kotlin (Java functions Vs Kotlin functions).

4. Using of null-safe (let keyword) in Kotlin. Don't need to check for null before performing any operation to that variable.

5. Use of Android studio shortcuts to convert code as per suggestion.

6) After converting code as per suggestion by android studio IDE and final run the application.