How to fix the "undefined symbol _main in module c0.ASM" error in TurboC++3?

edited February 2021 in Programming
void palette(int pnum)
union REGS r ; = 1 ; /* code for mode 4 */ = pnum ;
r.h.ah = 0xb ;
int86(0x10, &r, &r) ;
Why the above program has no problem in compiling but gives this error in the linker?
error:"undefined symbol _main in module c0.ASM"


  • edited March 2021
    All C++ have to have a int main() class with a "return 0;" from my understanding, and you are missing that.
    the pallette is a custom class you need to call from main. I'm no expert though, I just started learning C++
Sign In or Register to comment.