I have studied in c that variables that use keyword extern are externally referenced
for example:
Prog1.c
main(){
extern int a ;
a=2;
}
Prog2.c
int a=3;
these two programs are successfully compiled together. does that means that variable a in Prog2.c is having external linkage (external reference) as well ??
but it is written in dennis ritchie pg-195 section a4.1 that the objects declared outside all blocks, at the same level as function definitions, are always static and i think static means internal linkage so what is exactly happening in the above program?