extent:

Variable and functions, unlike types,have an existence at run time—that is,they have storage allocated to them. The extent of these objects is the period of time that the storage is allocated. Standard C calls this the storage duration.

An object is said to have static extent when it is allocated storage at or before the beginning of program execution and the storage remains allocated until program termination.

In C, all functions have static extent, as do all variables declared in top-level declarations.

Variables declared in blocks may have static extent depending on the declaration

An object is said to have local extent when it is created on entry to a block or function and is destroyed on exit from the block or function.

A variable with local extent is called automatic in C.

extern:

A special case of scope and visibility is the external  identifier, also called an identifier with external linkage . All instances of an external identifier among all the files making up a C program will be forced to refer to the same object or function and must be declared with compatible types in each file or else the result is undefined.

External names must be declared extern explicitly or implicitly, but not all names declared extern are external.

 

storage class:

A storage class specifier determines the extent of a declared object (except for typedef, which is special).

storage-class-specifier: one of

auto   extern   register  static   typedef

extern:

1. It indicates that the object declared has static extent and its name is known to the linker

 

static:

1.On function definitions, it is used only to specify that the function name is not to be exported to the linker.

2.On function declarations, it indicates that the declared function will be defined-with storage class static-later in the file.

3. On data declarations, it always signifies a defining declaration that is not exported to the linker. Variables declared with this storage class have static extent(as opposed to local extent, signified by auto).