When SecondActivity opens on top of MainActivity, MainActivity normally goes through:
- onPause() then onStop()
- onRestart() only
- onDestroy()
- 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