不像普通的變量,靜態成員變量是被所有類對象共享的,不同的對象可以訪問對方的該靜態成員變量,因此靜態成員變量和類對象並沒有聯系。
The static keyword has another meaning when applied to global variables -- it gives them internal linkage (which restricts them from being seen/used outside of the file they are defined in). Because global variables are typically avoided, the static keyword is not often used in this capacity.
Unlike normal member variables, static member variables are shared by all objects of the class.Static members are not associated with class objects