Would you like to clone this notebook?

When you clone a notebook you are able to make changes without affecting the original notebook.

Cancel

global and block-scoped

node v10.16.3
version: master
endpointsharetweet
var trigger = true; // Initialize a global variable let digimon = "Agumon"; if (trigger) { // Initialize a block-scoped variable let digimon = "Greymon"; console.log(`Evolution triggered, you are become ${digimon}.`); } console.log(`Evolution failed, you are still ${digimon}.`);
Loading…

no comments

    sign in to comment