Functions provide code re-usability i.e. once a function is written can be invoked anytime upon need.

They have one disadvantage too. They take more time to implement because the control has to jump from normal code to the functions and then returns back to the calling environment. This is known as Context Switching.

Information or data is passed to functions through parameters, if needed. Functions can be with or without parameters.

Functions if needed, can return some value or values or even a function. Thus function can have or cannot have return type.

Leave a comment