+ 1

What is void main?

I know void means valueless but put together with main, it doesn't just make sense for me

31st Jan 2017, 4:06 AM
<Ballad/>
<Ballad/> - avatar
2 Respuestas
+ 6
main is the method where every code starts
31st Jan 2017, 4:33 AM
David Sebastian Keshvi Illiakis
David Sebastian Keshvi Illiakis - avatar
+ 2
main is a function. Every function would need a return type. Since main is the function that starts everything, it requires no return value. Thus the void. Hence the void main.
31st Jan 2017, 7:18 AM
Deddy Tandean