Basic Structure Of C-Program

in computer •  11 months ago 

Hello people!

laptop-1839876_1280.jpg

Let us learn basic structure of c-program :-

IMG_20231106_201625.jpg

[1] Document Section : It consists of set of comments lines that consists name of the program, author an
and other details.

[2] Link Section : To include header file we need instruct the compiler from system library, such as #include (header file) comment.

[3] Definition Section : It defines all symbolic constants, such as using (#) comment.

[4] Global Declaration Section : The variables and functions that are needed are declared in this section.

[5] Main Function Section : Every c-program must have one main function section.
It is the main starting point of the program.
~It has two parts,
{a} Declaration part - It declares all variables that are used in the main function.
{b} Executable part - It contains statements used in the program and is executed by the compiler and thus gives the desired output.

[6]Subprogram Section : It defines all the functions other than main function.

IMG_20231106_205650.jpg

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE BLURT!