Functions in C Language

Опубликовано: 21 Март 2026
на канале: KIPS Learner's Channel
588
13

Many programs require a group of instructions to be executed repeatedly. These repeated instructions can be
placed within a function, which can be executed and accessed from different places as required. A computer
program cannot handle all the tasks by itself instead it requests other program like entities to get its task done
known as functions.
A Function is a block of code, which has a name and can be reused from any place.
Up till now, you have been writing the programs in a single function called main(). This works well for small
programs. As the complexity of the system increases, the entire program cannot be written in one function but
needs to be broken down into several functions, each of which would be performing a specific type of task.
These sub-tasks can be reused as required, and if anything goes wrong, then only one sub-task is needed to be
checked.