The method that can be used to create new properties and also to modify the attributes of existing properties is _________

The method that can be used to create new properties and also to modify the attributes of existing properties is _________
A. Object.defineProperty()
B. Object.defineProperties()
C. Both Object.defineProperty() and Object.defineProperties()
D. Object.inherit()
 
Answer: c
Explanation: The method Object.defineProperty() defines a new property directly on an object, or modifies an existing property on an object, and returns the object.Both Object.defineProperty() and Object.defineProperties() can be used todefine new properties.
 

Tìm kiếm

Back
Top