+ 1
void main() in C++
Correct me if I’m wrong, in C++, void main() doesn’t exist, but you can still use int main without returning a value. Does this mean that void main() is somewhat “included” in the int main()?
3 odpowiedzi
+ 2
//Here is a relevant thread, that gives you best answer
https://www.sololearn.com/Discuss/1225/?ref=app
+ 2
Just adding one more link on the compiler adding the return statement for main() if you do not write it explicitly.
http://www.stroustrup.com/bs_faq2.html#void-main