Basic Structure of C Programming
Documentation
Section
Single line comment
//Text……
Multi line comment
/*Multi
line comment*/
Link
Section
§Header Files
#include<x.h> Ã where x is a header
file like such as :
string.h---Ã for string handling function
stdio.h ----Ã for standardized
input and output functions
math.h
---Ã for mathematical
functions
alloc.h ---Ã for dynamic memory
allocation
conio.h --Ã for clearing the
screen
stdlib.h --Ã for some miscellneous
functions
Source Code file
Contain
source code of the program
Object Files
Generated
by the compiler as a result of
processing the source code
Binary Executable File
Generated
by the linker as a result of production
of binary files through the object filesthat can be directly executed on
Windows operating system in .exe
extension
Definition Section
Eg/ user define header file
#define MAX 50 etc…
*Here MAX is a constant whose value is 50
Global Declaration Section
When
the declare the variable before the main function of program
Main Section
§It consist of
Declaration part and executable part of the program
§Eg/ main()
{
declaration part // int
a,char b,float c etc..
executable part //
}
Subprogramming Sectio
In sub programing
section we may create a function for a particular task and call to main
function.
We may create more
than one function in a single program
§Eg / Function1()
Function2()
………..FunctionN()
Single line comment
//Text……
Multi line comment
/*Multi
line comment*/
Link
Section
§Header Files
#include<x.h> Ã where x is a header
file like such as :
string.h---Ã for string handling function
stdio.h ----Ã for standardized
input and output functions
math.h
---Ã for mathematical
functions
alloc.h ---Ã for dynamic memory
allocation
conio.h --Ã for clearing the
screen
stdlib.h --Ã for some miscellneous
functions
Source Code file
Contain
source code of the program
Object Files
Generated
by the compiler as a result of
processing the source code
Binary Executable File
Generated
by the linker as a result of production
of binary files through the object filesthat can be directly executed on
Windows operating system in .exe
extension
Definition Section
Eg/ user define header file
#define MAX 50 etc…
*Here MAX is a constant whose value is 50
Global Declaration Section
When
the declare the variable before the main function of program
Main Section
§It consist of
Declaration part and executable part of the program
§Eg/ main()
{
declaration part // int
a,char b,float c etc..
executable part //
}
Subprogramming Sectio
In sub programing
section we may create a function for a particular task and call to main
function.
We may create more
than one function in a single program
§Eg / Function1()
Function2()
………..FunctionN()
No comments:
Post a Comment