 We are going to see the concept of function in C. Learning outcome at the end of this session, students will be able to explain the need of function in programming and explain the function concept and types of function in C. Now first we see need of function, first need is improved modularity. Here we divide a large program into multiple modules. Nuclear programming technique makes it easier and simple to understand. Next improve readability, code readability leads to ease of debugging and extending. Next code reusability, once a function is written, it can be called and used repeatedly as and when required. It reduces the rewriting of the same function. Next we see the code reusability, consider an example, take the two integer value from the user and check whether the numbers are positive or negative. Here I have shown program initially without using function. First step is to include the essential header file. After that we start with the main function. Starting with the main function first let's declare one integer variable to store the number. Now get the values from the user using the scanf function. After that we check whether the number is positive or negative. So we require if else branching statement for checking our condition as shown below. The condition is to check whether the scan number is greater than zero. It means the number is positive else its negative number accordingly either statement first or second will be executed. Similarly we check for the second number. Here we follow the same steps as shown previously. Here we are rewriting the same piece of code again. This is not a good program practice hence function comes into scenario where this rewriting can be avoided. Program with function here we see how this can be done using function. First inclusion of essential header files. We define the function check for checking the positive or negative number. Here check function take one parameter num of type integer. Here we use if else statement for checking in if we specify the condition whether number is greater than zero if it is then display the message positive otherwise it display the message negative number and close the function. We define the main function. In main function first we declare the one integer type variable num for storing the num number. Here we use the scanf function to take the first number from the user and after that we call the check function for checking number is positive or negative. We pass the integer value that is stored in the num variable to check to the check function. Here we call the function check two times. Next is the debugging. Debugging means removing the errors in the program when there is an error in the program the programmer can check that function where the error is flagged and modify the function which contains the error without disturbing the other function flow. Next reduces the size of code. The use of functions reduces the length of the source code. Next we see the function. A block of code that performs a particular task is called function. The purpose of writing the program is to solve a given task. In programming generally complex task is divided into various subtasks. Then the programmer writes separate piece of code called functions to represent this task. Generally the main task is represented by the main function and the subtasks are represented by other functions. Thus we can say that every C program is nothing but a group of functions. See the figure. A function represents a group of statements that performs a specific task. Now next we will see types of functions. There are two types of functions. Predefined standard library functions and second is the user defined functions. Predefined standard library functions are those functions which are already defined in the C library for performing the some operations. For example, square root is a mathematical library function which is used to finding out the square root of any number. These functions, printf, scanf are the input-output library functions. Similarly, we have the functions like strlian, strcat functions for string manipulations and these functions are defined in the string.h header file. You just need to include the appropriate header files to use these functions. These are already declared and defined in the C libraries. For example, printf and scanf are already defined in stdi.h header file. Next function is a function type is a user defined function. A user defined functions are those functions which are defined by the user at the time of writing program. These functions are made for code reusability and for saving time and space. Now after seeing the function concept can you state whether string compare and putes is a user defined function or it is a built-in function. Pause this video and think about it. strcmp and putes is a built-in functions. Now one more question is that state whether the strcpy and strlian functions are defined in the string.h header file. State whether it is a true or false pause this video and think about it. strlian and strcpy functions are defined in string.h header files. These are the references. Thank you.