Difference between “int main()” and “int main(void)” in C/C++? – GeeksforGeeks

main() can be called with 0 or more arguments in C, while main(void) cannot be called with any arguments. In case of C++ both means main can be called only without parameters.

 

Source: Difference between “int main()” and “int main(void)” in C/C++? – GeeksforGeeks

About the Author

Yogi

21 years of experience in various layers of software. Primarily experienced in system side software design and development on server management software. Interested in linux development in x86 and arm architecture.