Just adding on what PDK has explained?
Every function is global by default until unless we specify the keyword “static” keyword before function name to make it static.
Example
static int StaticFunc(void)
{
printf("I am a static function ");
}
Static functions are restricted to the file where they are declared hence can be accessed by the other function of the same file but not by the other files.
Example
/* Inside file1.c */
static void StaticFunc(void)
{
puts("StaticFunc called");
}
/* Iinside file2.c */
int main(void)
{
StaticFunc(); // Error
return 0;
}