answersLogoWhite

0


Best Answer

Yes,we can compile our program without header file without any error,but we can not use any predefine functions like printf,scanf.

User Avatar

Wiki User

14y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Can you compile program without header file?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

What is the command to compile a java program named Greetingsjava?

The command to compile a Java program is "javac", followed by the class name (file name).


How is a library file incorporated in a C program?

Every library requires a header file (.h file) that can be included in any translation unit that requires access to the library. The header describes the library interface. The library implementation may be provided by a corresponding .c source file in which case you can compile the library into your program just as you would any other translation unit. However, most library implementations are provided by a precompiled library file (.lib file) and you generally won't have access to the source file. The precompiled library file is required by the linker while the corresponding header is required by the compiler.


C program without main functoin?

If we save our program with .c extention before compiling it, the compiler with automatically include the header files. for eg-First we save our program with sum.c and then compile it. It will not show any error.1. Compilation needs header files, not execution.2. Very small example programs can be written without using any header file, eg:/* mini.c */extern void (const char *puts);int main (void){puts ("Hello, world");return 0;}


What is the different between header file and header pointer?

Header file is a file which is meant to be included into another file during compilation. Examples: string.h, stdio.h, inttypes.h. Header pointer is a pointer to an object called header (for example header of a linked list).


What is the difference between program and programing?

the program contains the which are coding like as our header file ,void main,library function etc.

Related questions

How can you create a c program without using header file?

C programs do not require header files. If you want a C program without header files, you can simply not create them. However, you may or may not be able to include your non-header file source files.


What is the command to compile a java program named Greetingsjava?

The command to compile a Java program is "javac", followed by the class name (file name).


How do you compile php code?

If you are looking to create an executable (.exe) file on windows then I highly recommend this program to compile your php source code to an exe file.


How is a library file incorporated in a C program?

Every library requires a header file (.h file) that can be included in any translation unit that requires access to the library. The header describes the library interface. The library implementation may be provided by a corresponding .c source file in which case you can compile the library into your program just as you would any other translation unit. However, most library implementations are provided by a precompiled library file (.lib file) and you generally won't have access to the source file. The precompiled library file is required by the linker while the corresponding header is required by the compiler.


Any program in c plus plus without using any header file?

For example: int main (void) { return 0; }


How is the header file include within a program?

#include or#include "nameoftheader"


Is header file the library file?

No. Header files are those which contains declaration part of function & library files are those which contains definition part of function. These are those functions which we called in our program by using header files.


C program without main functoin?

If we save our program with .c extention before compiling it, the compiler with automatically include the header files. for eg-First we save our program with sum.c and then compile it. It will not show any error.1. Compilation needs header files, not execution.2. Very small example programs can be written without using any header file, eg:/* mini.c */extern void (const char *puts);int main (void){puts ("Hello, world");return 0;}


How to write a C program to find the header record in a file .please advice?

Just open the file, read-in N bytes and then examine (parse) for known header values or signature.


What are the file created after c file is save?

Having saved the source file (*.C), you can compile it into an object module (*.OBJ), then link an executable program (*.EXE)


How do you include classes and structures in header files in c plus plus?

Classes and structures can be put in a header file the same way you would use them in a main program; the only difference is that they are placed in a separate file, called a header file. Then, after creating a new file, include that new file with the definition by the use of the preprocessor #include statement.


What is the different between header file and header pointer?

Header file is a file which is meant to be included into another file during compilation. Examples: string.h, stdio.h, inttypes.h. Header pointer is a pointer to an object called header (for example header of a linked list).