g++ crashed when I tried to compile a program with ONE LINE

You haven’t defined main() function in your program.

As said in error:

(.text+0x20): undefined reference to `main'


This is not crash of g++, it just shows error message when can’t find definition of main().

Browse More Popular Posts

Leave a Comment