Saturday, February 21, 2009

Why do you need to declare variables?

Most of the programming languages want you to identify the name and the type of your variables in advance so that the compiler can set aside the memory the program will need to store and process the information held in the variables.
Memory management might not seem like a big deal to you, but in some programs, memory can be consumed quickly, and it’s good practice to take memory allocation seriously even as you take your first steps as a programmer.

Different types of variables have different space requirements and size limitations.

No comments: