Why won't the 'luck' function get executed?
Pasting the code of my tutorial in my compiler creates the exact same error as the little test code below:
'luck' undeclared. First use this function.
I use dev c++

Thx ;)

int main()
{
   printf("hellow (printed in main)\n");
   luck();
 
   return 0;
}
 
luck()
{
  printf("hellow again (printed in luck)\n");
}

Why won't the 'luck' function get executed?
Pasting the code of my tutorial in my compiler creates the exact same error as the little test code below:
'luck' undeclared. First use this function.
I use dev c++

Thx ;)

int main()
{
   printf("hellow (printed in main)\n");
   luck();
 
   return 0;
}
 
luck()
{
  printf("hellow again (printed in luck)\n");
}

declare as

void luck();

at top.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.