← Back to archive

Stdle #61 · scope · 2026-07-31

What does this JavaScript snippet output?

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

function f(a, b = a * 2) { return a + b; }
console.log(f(3));
Scope
4 attempts left

Answer & explanation