When SecondActivity opens on top of MainActivity, MainActivity normally goes through:

  1. onPause() then onStop()
  2. onRestart() only
  3. onDestroy()
  4. onCreate() again
Answer

A) onPause() then onStop()

The first activity becomes hidden, so it is paused and stopped but stays on the back stack.

Computer Science MCQ · More Lab: Multiple Activities and Navigation MCQs · Practise