Question: Describe what is happening in this code?

  1. It is creating a new object that contains the same name property as the person object.
  2. It is assigning the value of the person object's firstName property to a constant called name.
  3. It is retrieving the value of person.name.firstName.
  4. It is assigning the value of the person object's name property to a constant called firstName.

Answer: The correct answer of the above question is Option D:It is assigning the value of the person object's name property to a constant called firstName.