Android Basics: Add a button to an app
Learn more concepts in Kotlin—including classes, objects, and conditionals—to create an interactive app for your users.
Go back
Classes and object instances in Kotlin
Create a Kotlin program that generates random numbers to simulate rolling dice.
Create an interactive Dice Roller app
Learn how to add a button and modify the activity code of an Android app.
Add conditional behavior in Kotlin
Create a Kotlin program that uses conditionals to compare a user's dice roll with a given lucky number.
Add images to the Dice Roller app
Enhance the user experience by adding images to the Dice Roller app.
What can you build with these basics?
Learn where you can go from here!
Quiz
Test your knowledge of classes, objects, and conditionals in Kotlin, and earn your Dice Roller badge.