Get user input in an app: Part 1
Create a tip calculator app by building the layout first, then implement the logic to calculate the tip from the user input.
Welcome to Unit 2: Layouts
Learn about the two apps you’ll build in this unit to advance your knowledge about UI layouts in Android.
Tip calculator app introduction
Get a glimpse of the tip calculator app you’ll be building in this pathway.
Classes and inheritance in Kotlin
To build more complex apps, you’ll need to better understand how classes and inheritance work so that you can more fully use what the Android platform offers.
Create XML layouts for Android
Learn about new UI components, such as editable text fields, radio buttons, and switches to build up the layout for your tip calculator app. Instead of using the Layout Editor in Android Studio, you’ll be editing the layout for your app in XML.
Calculate the tip
Learn how to write Kotlin code to interact with the UI elements in the tip calculator app, so that you can calculate the tip. You’ll also learn how to handle edge cases in your app to make your app more robust.