Compilation Error: first time I saw today..please fix it ASAP

  • Error description:


      /usr/lib/gcc/i586-linux-gnu/4.9/../../../i386-linux-gnu/crt1.o: In function `_start':
        (.text+0x18): undefined reference to `main'
         collect2: error: ld returned 1 exit status 


  • I used language C++;

re-submit the solution

2 Likes

@bradely…thanks

can anyone tell why it heppens??

1 Like

This is shown when the compiler couldn’t find main function.

Maybe,by mistake while pasting the solution,your cursor might have deleted or altered the main function(or it may happen due to some other internal factors).This is the only possible reason I could think of.

There’s a detailed view on the similar problem-link

2 Likes

@ prrateekk…thanks a lot

Can you post the link of your solution(old and new)?

1 Like

@prrateekk…thanks for your effort…

.I solved that issue

this time I don’t have that solution…

//