thanks. one question tho
Satan (impatiently) to Newcomer: The trouble with you Chicago people is, that you think you are the best people down here; whereas you are merely the most numerous.
- - - Mark Twain ÂPuddÂnhead WilsonÂs New Calendar,Â 1897
scope and execution...
If you don't it is included in "everything"... and makes it slower in execution and hog memory.
You really need to instrument your stuff to see the difference, but if you have multiples... it'll compound the execution time.
PGP key 1024D/B524687C 2003-08-05
Fingerprint: E1D3 E3D7 5850 957E FED0 2B3A ED66 6971 B524 687C
It makes for tidier code.
Namespacing it means you use more concise names without risking a collision. It also makes it much easier to create private variables and functions for your code.
Call it defensive programming.
Just Add Story http://justaddstory.wordpress.com/
Avoids name collisions.
If you have a global function named foo(), and a 3rd party library or someone else in your organization comes along and defines foo() as well, There Can Be Only One and the first defined will lose.
As Wade mentioned, it's also a tidiness thing. Everything in one place can make for a giant morass of code to sort through. Take a traipse through the Window object (where everything in global scope is put) some time to see all the stuff already in there.
Welcome to Rivendell, Mr. Anderson.