Confused about JavaScript prototypal inheritance
In the book " JavaScript the definitive guide 5 edition ", section 9.2 Prototypes and Inheritance, I find the following words: In the previous section, I showed that the new operator creates a new, empty object and then invokes a constructor function as a method of that object. This is not the complete story, however. After creating the empty object, new sets the prototype of that object. The prototype of an object is the value of the prototype property of its constructor function. All functions have a prototype property that is automatically created and initialized when the function is