Yes. "extern int u;" in f2.c.
Yes. "extern int u;" in f2.c.
yes, I know. I put that there to show that you needed to declare it with an extern in the file.
That's untrue. It works the same as in C. You have to declare it as "extern" in the other modules that reference it.
Have you EVER worked on code composed of more than a single source file?Internal linkage in C. Cannot be accessed from other .c files.Code:static int x = 5;
I don't know what the effect is in C++, though. I don't know if it will cause external linkage in this case.