Why does javascript allow the creation of global variables in local code?
An example
function f() { x=10; }
function g() { print(x); }
f(x);
g(x);
Why does javascript allow the creation of global variables in local code?
An example
function f() { x=10; }
function g() { print(x); }
f(x);
g(x);