INT MAIN | Sololearn: Learn to code for FREE!



what are the advantage of using int main???

11/15/2016 2:21:33 PM

sanket jain

5 Answers

New Answer


just int main() will work everywhere, while void main() will not..


so basically the return value from the main() function is used by the runtime library as the exit code for the process......right?


void doesn't returns any type while int or anything else does.


The int part of int main() is good, because it will work universally, and gives you the ability to terminate your program prematurely.


you u can use it ,when u need Ur main function to return some int values