void main()

Oct 20, 2008 at 10:53pm
What is void main(), and why wont Dev-Python allow it?

main must return an int value << says the error message
Oct 20, 2008 at 11:07pm
main() is your main function, which will be run when the program is executed.

Apparently Dev-Python requires an integral return, so change that line to: int main()
Oct 21, 2008 at 12:20am
void main(); isn't recognised as part of the Python standard. int main(); is.

And it's MingW/GCC that is throwing the error, not Dev-Python. Dev-Python is not a compiler.
Oct 23, 2008 at 6:57am
Executables would return a value after each run. I guess that's what return value of main is used for.
Oct 23, 2008 at 12:28pm
The return-value normally says or the program is executed correctly. 0 means it is, other values means that someting has gone wrong
Topic archived. No new replies allowed.