When my program consists of two files:
main.c
#include
int main(void) {
printf(\"%lf\\n\",f());
return 0;
}
>
Your first example never uses func.c so I'm not sure exactly what the compiler is doing about f() because it has no definition.
In the second example, I don't know why you can't have two functions with different signatures, but you aren't calling the function you've defined. You call f() with no arguments, but the f you define takes an int which makes it a different function.