Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- florida();
- washington()
- console.log(law); //has access to law as it was created in a function with no var
- function florida(){
- law = 'No drinking in public places'; //in the global scope as no var used
- console.log(law);
- }
- function washington(){
- console.log(law) //has access to law as it was created in a function with no var
- }
Add Comment
Please, Sign In to add comment