Talk:Some SJS - POW Oddness
From PlainOldWebserver
a feature of javascript
It is a feature of javascript. You can write a variable but not declare it. If you do, it will create in global scope. Asymmetrically, you cann't read a variable but not declare it. It isn't a bug of POW. --LungZeno 10:38, 18 October 2010 (PDT)
- Anyway, if you declare it (through static code, not "eval"), you can write or read it before or behind where you declare it. To start a program or function, before run its code, all variables declared in the scope (through static code, not "eval") will be defined but have a value called undefined. --LungZeno 11:00, 18 October 2010 (PDT)