1

use of header files

view story
linux-howto

http://ubuntuforums.org – Hello, I am sorry, but I still haven't been able to understand why header files are used, in spite of having read a lot about it. I understand that if you are using a function from another C file/library, then you use a header file which has the function declaration instead of declaring the function in every C file which uses it. But .. can't this be done even without the header file, if all the C files are linked to form the same executable. Consider these 2 .c files Code: main.c #include <stdio.h> int main(void) {  fun(1);  return 0; } support.c #incl (Hardware)