for (let i = 0; i != 3; i += 1) { console.log(i); // i refers to the variable defined below const i = 0; }
And here is another one, upvar in Tcl.