QuestenaПрактика, после которой понятно, что повторить
Вопрос 65

A new ordinary object is stored in person. The program executes person.name = "Ada" under normal writable conditions. What changes?

  1. person gains an own name property containing AdaПравильный ответ
  2. A local variable named name is created
  3. The property is added only to person's prototype
  4. Nothing changes because missing properties cannot be assigned

Объяснение

Ordinary assignment through a previously absent name creates that name as an own property and stores the supplied value. It does not create a separate local binding named name, because the assignment target is a property access.

Продолжить работу с тестом

Начать тренировку
Вопрос 65: A new ordinary object is stored in person. The program… · JavaScript Fundamentals · Questena