Suppose I have a header file : header.h
const int i =10;
Multiple source files can have access to this variable "i" just by including this header file. Since it is a constant, none of the source file can change the definition. So what will happen if I change header.h like this:
extern const int i;
And define i in any of the other .cpp file.
In other words, how does it matter if "i" has internal(every source file has its own definition) or external(definition is shared) linkage because in any case definition of "i" will never change.What is the advantage of making it extern?