< Previous | Contents | Next >

Minimizing the Use of Global

Variables

Just because you can doesnt mean you should. This is a good programming motto. Sometimes things are technically possible, but not a good idea. Using global variables is an example of this. In general, global variables make programs confusing because it can be difficult to keep track of their changing values. You should limit your use of global variables as much as possible.