Question: What is the chief purpose of line five in this code snippet?

  1. to make sure that the activity finishes when the savedInstanceState is not null
  2. to make sure that the activity creates a new fragment each time it is restored from a previous state
  3. to prevent the display of two fragments side by side in cases where the activity is restored from a previous state
  4. to prevent the creation of overlapping fragments in cases where the activity is restored from a previous state

Answer: The correct answer of the above question is Option B:to make sure that the activity creates a new fragment each time it is restored from a previous state