0
0
Android Kotlinmobile~5 mins

Android SDK and API levels in Android Kotlin - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What is the Android SDK?
The Android SDK is a set of tools and libraries that developers use to build Android apps. It includes things like the Android platform, emulator, and build tools.
Click to reveal answer
beginner
What does API level mean in Android development?
API level is a number that represents the version of the Android platform. It helps developers know which features and behaviors are available on a device.
Click to reveal answer
intermediate
Why is it important to set a minimum SDK version in your Android app?
Setting a minimum SDK version ensures your app only runs on devices that support the features you use. It prevents crashes on older devices.
Click to reveal answer
intermediate
What is the difference between compileSdkVersion and targetSdkVersion?
compileSdkVersion is the Android version you use to build your app. targetSdkVersion tells the system which Android version your app is designed for, affecting runtime behavior.
Click to reveal answer
intermediate
How can you check the API level of a device programmatically in Kotlin?
You can check the API level using: val apiLevel = android.os.Build.VERSION.SDK_INT. This returns the device's API level as an integer.
Click to reveal answer
What does the API level number represent in Android?
AThe number of apps installed
BThe version of the Android platform
CThe device screen size
DThe app's version code
Which SDK version should you set to ensure your app uses the latest Android features during build?
AcompileSdkVersion
BtargetSdkVersion
CminSdkVersion
DmaxSdkVersion
If your app's minSdkVersion is 21, what does this mean?
AThe app supports all API levels
BThe app targets API level 21
CThe app only runs on devices with API level 21 or higher
DThe app compiles with API level 21
What happens if you run an app on a device with an API level lower than minSdkVersion?
AThe app crashes or won't install
BThe app runs normally
CThe app updates the device's API level
DThe app runs in compatibility mode
How do you get the current device API level in Kotlin?
Aandroid.device.apiLevel
BSystem.getApiLevel()
CBuild.VERSION_CODE
Dandroid.os.Build.VERSION.SDK_INT
Explain the roles of minSdkVersion, targetSdkVersion, and compileSdkVersion in Android app development.
Think about compatibility and build process.
You got /3 concepts.
    Describe why understanding API levels is important when developing Android apps.
    Consider how devices differ by Android version.
    You got /3 concepts.