JavaScript Interview Question: How Does Prototypal Inheritance Work?
Short answer: every JavaScript object has an internal link to another object, its prototype . When you read a property that the object doesn't have, JavaScript looks it up along this prototype chain until it finds it or reaches null . const animal = { speak()...