I've never tried to include other .c files into a program before, so any help would be appreciated.
If the following were the case:
/*menuprog.c*/
#include<stdio.h>
#include "p1.c"
#include "p2.c"
#include"p3.c"
if a structure/ variable/ function was declared in, for instance, p1.c
would it then become unneccessary to declare it in any of the other files or even (in this case) the menuprog.c file?
Are functions called from other files just by the function name?
Is passing values to the functions done in the same way as if the function were in the same program?
Would I be right in thinking that variables can only be accessed if they are declared extern?
Thanks.