(function(){ var foo = 'Hello world'; })(); console.log(foo); // undefined!