Scope of a static (class) variable

Once declared and globally initialized, a public or private static variable is accessible by all of the static and non-static functions defined in the same class.

A public static variable is accessible by any code in any function (including global functions) in the program that knows the name of the variable and the name of the class in which it is declared.