← Back to archive

Stdle #108 · scope · 2026-09-16

What does this JavaScript snippet output?

A past puzzle — fully playable. 4 attempts, hints on wrong guesses.

const proto = { toString() { return "P"; } };
const o = Object.create(proto);
console.log(o.hasOwnProperty("toString"), `${o}`);
Scope
4 attempts left

Answer & explanation