Easy everything in Mobile Dev, page 8

What is the purpose of `remember` in Jetpack Compose?
This tests your grasp of Compose's recomposition lifecycle. A good answer explains remember caches an object across recompositions, preventing state loss. It's used with mutableStateOf to hold the same state instance.

LinearLayout vs. RelativeLayout vs. FrameLayout
This tests your knowledge of fundamental View layouts and performance trade-offs. Define LinearLayout (single axis), RelativeLayout (relative positioning), and FrameLayout (stacking), giving a clear use case for each.

Started vs. Bound Services: Differences and Use Cases
Tests Android component lifecycle and IPC knowledge. A good answer defines lifecycle control (start vs. bind), communication (one-way vs. two-way IBinder), and gives clear use cases. A red flag is assuming services run on a background thread by default.

What happens to an Activity and its text on screen rotation?
Tests understanding of configuration changes and state preservation. A great answer explains the Activity is destroyed and recreated, EditText state is often saved automatically, but the robust solution is using a ViewModel with SavedStateHandle.

Trace an Activity's lifecycle when a user navigates away and returns
This tests your understanding of resource management and state preservation, not just memorization. A great answer traces onPause -> onStop when leaving, and onRestart -> onStart -> onResume when returning, explaining what happens in each.

What is the `res/` directory and how do you use resource qualifiers?
This tests your grasp of Android's resource system. Explain that res/ separates assets from code and that qualifiers (e.g., layout-land) let the OS pick the right layout. A red flag is checking orientation manually in code instead of using this system.

Difference between project and module build.gradle files?
This tests your understanding of Gradle's project structure and build configuration scope. The project-level file configures global settings like repositories, while the module-level file configures specifics like dependencies and app ID.

Purpose and Key Elements of AndroidManifest.xml
Tests if you know the manifest is the app's contract with the Android OS. A good answer defines its role and lists key elements like activities, permissions, and the launcher intent. A red flag is calling it just a generic 'config file'.

Explain Kotlin's scope functions: let, run, with, apply, also
This tests your grasp of idiomatic Kotlin and the two key differentiators: context object (this/it) and return value (object/lambda result). A great answer defines these axes, categorizes each function, and provides a clear example.

What is a `suspend` function in Kotlin?
Tests your grasp of Kotlin's core concurrency primitive. A suspend function can pause and resume. It must be called from another suspend function or a coroutine builder.

Difference between launch and async in Kotlin Coroutines
This tests your grasp of coroutine result handling and exception propagation. Explain that launch is fire-and-forget (returns Job), while async is for results (returns Deferred). Mention async defers exceptions until await().

Purpose of Kotlin's safe call (`?.`) and Elvis (`?:`) operators?
This tests your grasp of Kotlin's null safety philosophy. A good answer defines the safe call (?.) for conditional access and the Elvis operator (?:) for default values, then combines them. A red flag is using verbose if/else checks for simple cases.

Explain val vs. var and null safety in Kotlin
Tests your grasp of Kotlin's core principles: immutability and compile-time null safety. Define val (read-only) vs. var (mutable), declare nullables with ?, and identify the risk as runtime NullPointerExceptions.

How to pass data between Fragments with Jetpack Navigation?
This tests your knowledge of type-safe argument passing in Jetpack Navigation. A good answer defines the argument in XML, uses the Safe Args plugin to generate code, passes data via the Directions class, and retrieves it with the Args class.

Explain ViewModel, Repository, and Data Source in MVVM
This tests your grasp of separation of concerns in Android. A good answer defines ViewModel, Repository, and Data Source roles, then traces the unidirectional data flow. A red flag is having the ViewModel directly access a data source like Retrofit.

What problem does Jetpack ViewModel solve during configuration changes?
This tests your understanding of state loss during configuration changes. A good answer explains that Activities are destroyed on rotation, and ViewModel survives this event, preserving UI state.

How to arrange UI elements in Jetpack Compose?
This tests your grasp of Compose's declarative layout basics. A good answer defines Column (vertical) and Row (horizontal) for structure, and Modifier for decoration, size, and behavior. A red flag is confusing Modifiers with simple styling.

What is the purpose of the `remember` function in Compose?
This tests your grasp of recomposition. Explain that remember stores an object in the composition tree, preventing it from being re-initialized on every render. A red flag is confusing it with rememberSaveable, which survives configuration changes.

LinearLayout vs. RelativeLayout vs. FrameLayout: Explain and give use cases
Tests your grasp of classic Android layouts and performance trade-offs. A good answer defines each, gives a clear use case, and mentions layout_weight. A red flag is proposing nested LinearLayouts for complex UIs, ignoring performance.

Started vs. Bound Services: Differences and Use Cases
Tests your grasp of Android component lifecycles. A strong answer defines each by its lifecycle control (who starts/stops it) and communication pattern (fire-and-forget vs. client-server), then gives distinct use cases.
We are hiring for this. Every open role lists the topics its interview covers, so you can prepare for the real thing rather than guessing.
See open roles