const proto = { greet() { return 'hello'; } };
const obj = Object.create(proto);
obj.greet(); // 'hello'Object.create() creates an object with a specified prototype for inherited methods.
Object.create(proto) creates a new object with the specified prototype object. This is the standard way to set up prototype inheritance without using constructor functions.
Challenge: Use Object.create() to create objects that inherit methods from a custom prototype.