I appreciate the help there. Now I remember having to do that with C, and I should have tried it this as well.

Just seems kind of odd though. Why do I have to do it with this member variable, and I don't for member variables of other classes? Or do I? I could just be forgetting, but I don't remember having to do this with static member variables in the past. It's been a while since I've done C++, but I did Java recently and can't remember this being a necessity.

The reason this trick is necessary for static members of C++ classes (or for static variables in C) is the fact that we tend to have dumb linkers. In theory, it is possible to do away with needing to explicitly declare static variables, but that theory relies on having a smart linker (eg one that can look at multiple object files that all declare a static, work out they all need to refer to exactly one value, and assign that value for them to refer to).

The C and C++ standard basically require that statics are explicitly allocated at most once. If you don't allocate a static at all then, in practice, you run foul of dumb linkers. If you allocate a static only once, then dumb linkers are happy and smart linkers will effectively ignore the declaration. If you allocate a static more than once (eg in multiple source files) the standards explicitly state that you invoke undefined behaviour --- i.e. you shouldn't do it.

The reason it is not necessary in Java is that Java has a simpler compile and link model (eg everything is forced to be declared in a class). That's a trade-off; while the handling of static variables is simpler and cleaner for the Java programmer, some things that are easier in C or C++ because of the way those languages allow handling compilation and linkage of multiple files.