Creating global variables

Global variables are visible to all classes in the same package.
Note: Exercise caution when using global variables. If a global variable is used for a counter in a shared library and multiple threads or processes can access the counter, inaccurate results might occur if the global counter is not protected by a mutex or semaphore.

Feedback