Without the static line in file1.cpp being commented out I get 300 201 300. So the extern in the function is not being used but the static variable is instead. If I do comment out the static line I get 300 301 301 which is what I expected. Why does the static declaration override the extern?
maxcy / wt1v