C Tutorial/Language/External references
External references
Extern definition is used when referencing a function or variable defined outside.
// Program in file externa1.c
#include <stdio.h>
#include <c:\f1.cpp>
extern int i;
main()
{
i =0;
printf("value of i %d\n",i);
}