From the course: Android Development Essential Training: 1 Your First App

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Programming for Android with Kotlin

Programming for Android with Kotlin - Android Tutorial

From the course: Android Development Essential Training: 1 Your First App

Start my 1-month free trial

Programming for Android with Kotlin

- [Instructor] Modern Android applications are developed using the Kotlin programming language. However, it's worth noting that the Android SDK was built using an open source Java implementation. So you'll find classes for common Java APIs like java.lang, java.text, and java.io. When creating a new project in Android Studio, you have the option to choose either the Kotlin or Java programming language. In this course, we'll be working exclusively with the Kotlin programming language. Kotlin's type system puts nullability front and center. This is a known cause of many programming errors. The Kotlin compiler enforces that variables that cannot hold null values will cause a compilation error if you attempt to set them to null, just like we see here. Conversely, if you explicitly declare that the variable can be nullable, you're good to go. This can prevent you from experiencing the dreaded NullPointerException that Android…

Contents