Preprocessor – C Multiple Choice Questions and Answers

Which of the following are C preprocessors?

The #include directive

Explanation: The #include directive tells the preprocessor to grab the text of a file and place it directly into the current file and are statements are typically placed at the top of a program.

Property which allows to produce different executable for different platforms in C is called?

Explanation: Conditional compilation is the preprocessor facility to produce different executable.

C preprocessor is conceptually the first step during compilation.

#include is called

The preprocessor provides the ability for _______________.

Explanation: The preprocessor provides the ability for the inclusion of header files, macro expansions, conditional compilation, and line control.

#include are _______ files and #include “somefile.h” ________ files.

Explanation: Both of these statement can be used to select any file.

Preprocessor feature that supply line numbers and file names to compiler is called?

#include statement must be written.

Explanation: Using these directives before main() improves readability.

C preprocessors can have compiler specific features.

Explanation: #pragma is compiler specific feature.

If #include is used with file name in angular brackets.

Explanation: With the #include, if the filename is enclosed within angle brackets, the file is searched for in the standard compiler include paths.

The C-preprocessors are specified with _________symbol.

Explanation: The C-preprocessors are specified with # symbol.

A preprocessor is a program.

Explanation: A preprocessor is a preprocessor is a program that processes its input data to produce output that is used as input to another program.

#pragma exit is primarily used for?

Explanation: It is primarily used for running a function upon existing the program.