1. Junior

    What are the basic stages of the Activity lifecycle in Android and how does it move between them?

    It goes through six main stages: onCreate, onStart, onResume, onPause, onStop, and onDestroy, and it is visible and interactive at onResume.

    Read the full explanation
  2. Junior

    What is the difference between the Fragment lifecycle and the Activity lifecycle and why do we use viewLifecycleOwner?

    A Fragment has two lifecycles: one for the Fragment itself and another for its view, and you should use viewLifecycleOwner to observe data to avoid memory leaks.

    Read the full explanation
  3. Junior

    What is the difference between Application Context and Activity Context and when do you use each?

    Activity Context is tied to the screen's lifecycle, themes, and UIs, while Application Context lives for the whole time the app runs and you use it for global operations and singletons.

    Read the full explanation
  4. Junior

    What is the difference between an explicit intent and an implicit intent in Android?

    An explicit intent specifies the target component by its explicit name inside the app, while an implicit intent declares the required action so the system picks the suitable app.

    Read the full explanation
  5. Mid-level

    What are the launch modes of an Activity and what is their effect on the back stack?

    They determine how the Activity opens within tasks: standard (always a new instance), singleTop (reuse the top), singleTask (one instance per task), and singleInstance (an isolated task).

    Read the full explanation
  6. Mid-level

    What happens on a configuration change (such as screen rotation) and how do we preserve data?

    The system recreates the Activity entirely; we preserve non-transient data through a ViewModel, and essential lightweight state (such as identifiers and input text) through SavedStateHandle or onSaveInstanceState so it survives process death.

    Read the full explanation
  7. Mid-level

    What is the role of a ContentProvider in Android's architecture and when do you need it?

    It is a central component for managing and sharing structured data between different apps securely through an interface based on Uri paths.

    Read the full explanation
  8. Mid-level

    What is the difference between a statically registered and a dynamically registered BroadcastReceiver?

    A statically registered one is declared in the manifest and the app is woken up to receive it, while a dynamic one is registered programmatically in code and lives with the lifecycle of the component that registered it.

    Read the full explanation
  9. Senior

    What is the difference between full process death and the user closing the Activity?

    A user closing ends the Activity and clears its objects and state by their own choice, while process death happens forcibly by the system to free memory, with the SavedState preserved to restore it later.

    Read the full explanation
  10. Senior

    How do you apply the runtime permissions model in modern Android?

    You request dangerous permissions only when they are needed while the app is running, with a logical rationale and handling of permanent denial.

    Read the full explanation