The function main( ) invokes other functions within it.It is the first function to be called when the program starts execution.
?It is the starting function
?It returns an int value to the environment that called the program
?Recursive call is allowed for main( ) also.
?It is a user-defined function
?Program execution ends when the closing brace of the function main( ) is reached.
?It has two arguments 1)argument count and 2) argument vector (represents strings passed).
?Any user-defined name can also be used as parameters for main( ) instead of argc and argv
main is function which must be needed in our program it does'n matter where you write your main function in your program but it will starts execution from main our program will compile without main but to RUN it we must need Main() function.Main() behave like a function its by default datatype is INT, thats why we cant define a function inside main() as we know that we cant define a function within a function we can only call a function from other function.when our program starts it first looks for main and than it starts its execution from so without main we cant RUN our program.
In our c program,every program starts with main() because it tells the c compilor where the program sarts its execution.it returnes always integer value.it is a well defined user defined function.it has two arguments argc and argv,argc is a integer type and argv is a char type pointer vector.