PUBLIC QUESTION PREVIEW
Kotlin & Android interview questions
Kotlin language features, Android architecture (MVVM), Jetpack Compose, coroutines, Room, Retrofit, and testing.
Showing 12 of 40 source questions. Sample answers are study material, not employer-specific hiring guidance.
How to work through this preview
Attempt each question before reading its answer. For a concept, give a definition and a concrete example. For code, state constraints, walk through a small input, and check complexity. For design, separate requirements from assumptions and explain failure handling. Use real situations for behavioral answers.
QUESTION 1 / easy / conceptual
What is Kotlin? What advantages does it have over Java for Android development?
Sample answer
Hints to guide your next attempt
- Null safety, concise syntax, coroutines, interoperable with Java
Source tags: kotlin / android / java / advantages / null-safety
QUESTION 2 / easy / conceptual
What are Kotlin data classes? What is generated automatically?
Sample answer
Hints to guide your next attempt
- equals, hashCode, toString, copy, componentN functions generated automatically
Source tags: data-class / kotlin / equals / hashcode / copy / destructuring
QUESTION 3 / medium / conceptual
What are Kotlin sealed classes? When do you use them?
Sample answer
Hints to guide your next attempt
- Closed class hierarchy, exhaustive when expressions
- UI state, result types
Source tags: sealed-class / kotlin / when / ui-state / android
QUESTION 4 / medium / conceptual
What are Kotlin coroutines? How do they differ from threads?
Sample answer
Hints to guide your next attempt
- Lightweight, suspendable, no thread blocking
- launch vs async, Dispatchers
Source tags: coroutines / kotlin / async / suspend / dispatchers / android
QUESTION 5 / easy / conceptual
What is the Android Activity lifecycle? Name all callbacks.
Sample answer
Hints to guide your next attempt
- onCreate → onStart → onResume → onPause → onStop → onDestroy
- When does each run?
Source tags: activity-lifecycle / android / oncreate / onresume / ondestroy
QUESTION 6 / medium / conceptual
What is the Fragment lifecycle? How does it relate to Activity lifecycle?
Sample answer
Hints to guide your next attempt
- Fragment has its own lifecycle nested inside Activity lifecycle
- onAttach, onCreateView, onViewCreated
Source tags: fragment / lifecycle / android / onviewcreated / viewlifecycleowner
QUESTION 7 / medium / conceptual
What is MVVM architecture in Android? Explain the role of ViewModel, LiveData, and Repository.
Sample answer
Hints to guide your next attempt
- Separation of concerns
- ViewModel survives rotation, Repository abstracts data sources
Source tags: mvvm / viewmodel / livedata / repository / android / architecture
QUESTION 8 / medium / conceptual
What is the difference between LiveData and StateFlow/SharedFlow?
Sample answer
Hints to guide your next attempt
- LiveData is lifecycle-aware, StateFlow is coroutine-based
- StateFlow is preferred for new code
Source tags: livedata / stateflow / sharedflow / kotlin / android / flow
QUESTION 9 / medium / conceptual
What is Room? How do you define a database, DAO, and Entity?
Sample answer
Hints to guide your next attempt
- ORM on top of SQLite
- @Entity, @Dao, @Database, @Query annotations
Source tags: room / sqlite / dao / entity / android / database
QUESTION 10 / medium / conceptual
What is Retrofit? How do you make network calls in Android?
Sample answer
Hints to guide your next attempt
- Type-safe HTTP client, suspend functions, Gson/Moshi converters
Source tags: retrofit / networking / kotlin / android / api / okhttp
QUESTION 11 / medium / conceptual
What is Hilt? How does dependency injection work in Android?
Sample answer
Hints to guide your next attempt
- Built on Dagger, scoped components
- @HiltAndroidApp, @Inject, @Module, @Provides
Source tags: hilt / dependency-injection / dagger / android / kotlin
QUESTION 12 / medium / conceptual
What is Jetpack Compose? How does it compare to XML-based Views?
Sample answer
Hints to guide your next attempt
- Declarative UI, recomposition, Composable functions
- No XML, no ViewBinding
Source tags: jetpack-compose / declarative-ui / android / kotlin / recomposition
Check understanding, not recognition
- Can you explain the answer without reading it?
- Can you show when the approach fails or needs a different assumption?
- Can you connect the concept to a real project, task, or decision you have made?
- Can you distinguish a simplified interview example from a production requirement?
A LITTLE MORE CLARITY
Frequently asked questions
How many Kotlin & Android questions are shown here?
This public preview shows 12 questions with the supplied answers from the app's 40-question Kotlin & Android bank. Full interactive practice requires signing in.
Should I memorize the sample answers?
Use them as reference explanations, not a script or a guarantee of technical correctness for every environment. Explain your assumptions, validate code against your language and version, and discuss trade-offs. Behavioral answers should be built from your own experience.
What do hints and solution steps mean?
Hints identify ideas to consider before reading the answer. When the source question includes steps, they are shown as a separate walkthrough. Example capacities and design targets in a solution are assumptions for that exercise, not real system statistics.
BUILD YOUR NEXT OPPORTUNITY
Practice Kotlin & Android actively.
Sign in to use the full topic bank and interactive practice workspace.