function Foo(x) {
this.x = x;
return { x: x * 2 };
}
function Bar(x) {
this.x = x;
return 42;
}
const f = new Foo(5);
const b = new Bar(5);
console.log(f.x, b.x, f instanceof Foo, b instanceof Bar); Post #3510
573
CHALLENGE