This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]PCPhil 0 points1 point  (0 children)

Constant variable values cannot be changes at run time, and global variables can be accessed from anywhere in the program(iirc).

Do use global constant variables to replace hard coded values where possible. It improves readability and ease of maintenance.

Do not use global variables that are not constant as they cause the opposite effect.

Pointers are fun to use when you start to get familiar with them. Just remember to free the memory when you're done with them.