6. What is the #include directive used for?
It causes the compiler to substitute for that line the contents of some other file. In some cases it will be a library header, such as <stdio.h>. Sometimes these library header files are actually built in to the compiler. In other cases the included file will be a file that I have created, such as "myfunctions.h".
I use the #include directive so that I can reuse code in my programs, without having to reinvent functions that have already been invented.
No comments:
Post a Comment