console.log({ a: 1, b: 2, __proto__: { c: 3 } }.c);
const knowns = new Map([
[Object, 'Object'],
[Function, 'Function'],
[Array, 'Array'],
[Object.prototype, 'Object.prototype'],
[Function.prototype, 'Function.prototype'],
[Array.prototype, 'Array.prototype'],
]);
console.log(knowns.get(Object.getPrototypeOf({})));
Object.getPrototypeOf({}) === Object.prototype;
Object.getPrototypeOf([]) === Array.prototype;
Object.getPrototypeOf(/a/) === RegExp.prototype;
function Constructor() {}
Object.getPrototypeOf(new Constructor()) === Constructor.prototype;
Array.prototype.myMethod = function () {};
Object.getPrototypeOf({}).__proto__;
Object.getPrototypeOf([]).__proto__ === Object.prototype;
Array.prototype.__proto__ === Object.prototype;
class Clazz1 {}
class Clazz2 extends Clazz1 {}
console.assert(typeof Clazz1 === 'function');
console.assert(Clazz1.constructor === Function);
console.assert(Clazz2.constructor === Function);
console.assert(Clazz2.__proto__ === Clazz1);
console.assert(Object.getPrototypeOf(Clazz2) === Clazz1);
console.assert(Object.getPrototypeOf(Clazz1) === Function.prototype);
console.assert(new Clazz2().constructor === Clazz2);