Extern "C" is the concept that may be frequently checked during an interview.
Reference to this is an article in Baidu -
http://baike.baidu.com/link?url=m1JCaCULHSOg-b7ubUZoyJj29QtRFBO8HqnFvQ_SEAAXRV3qfcJAA8U0NFI2bSNgr_o7ZuoEDfJEq6T8k6na8_
It's not quite accurate, but it's good for a starter to look into. Suggest you google this and read some explanation in stackover.com.
Basically, we can use C libs(C source code compiled by C compiler, e.g. GCC) and even some other supported programming languages in C++ programming, and vice versa. Focus on C and C++.
C++ covers C, in terms of whatever standards or compilations. But C++ compiles the C/C++ in a different way from the way of C compiler. So, if we want to call the functions or interfaces that were compiled in C compiler in C++ programming, we have to point out that those interfaces were compiled by C, so that C++ compiler can put the according function symbols during the compilation and linkage will then be successful. The extern "C" implements this.
Many articles don't specify the C interfaces were already compiled by the C compiler. If we have got the C source code, we even don't need the extern "C" in C++ programming. We just use C++ compiler to recompile all c code.
In my mind, I can figure out two scenarios in which extern "C" will be necessary:
a: Some organization implemented the libs and they just provide us with the binary code(compiled via C) and the head files that expose what interfaces(function declarations) are implemented in their libs.
Then we can include such head files, and specify the extern "C" in C++ programming.
b: Even we have got the C source code and we have re-compile them in our C++ development environment, we need to move or integrate the C compile-environment to our C++ ongoing compile-environment. This will add to our complexity.
So, to keep it simple, we can separate the C and C++ compile-environment. Still use the original C compile-environment and build out the binary code, then just link them to the C++ program.