FUNCTIONS IN C LANGUAGE
Self contained block of 1 or more statements or a sub program which is designed for particular task is known an function.
ADVANTAGES
Self contained block of 1 or more statements or a sub program which is designed for particular task is known an function.
ADVANTAGES
- Module approach: by using functions we can develop the application in module format i.e. procedure oriented language concept.
- Resuability: By using functions we can create resuability blocks.
- By using functions we can easily debug the program.
- code - maintainance When we are developing the application by using functions then it is easy to maintain code for future enhancement.
PROPERTIES
- The basic purpose of function is reuse.
- A c programming is colloctions of functions.
- Always compilation process will take place from top to bottom.
- Execution process starts from main and ends with main only.
- When we are working with functions, functions can be defined randomly.
- Declaration of function means required to specify return type, name of the function& parameter type information.
- In function definition first line is called function header/ function prototype.
- Always function declaration must be required to match with the function declaration.
- When the function is not returning any value then specify the return type as void.
- Void means nothing i.e. no return type.
- Default parameter type of function is void.
Comments
Post a Comment