Wednesday 8 November 2017

Preprocessor Questions in C


More Preprocessor Topics:

Fill The Blanks Preprocessor Questions
Output Preprocessor Questions

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

A.  File inclusion
B. Selective inclusion
C. Conditional compilation
D. Recursive macros

Answer: C

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

---------------------------------------------------------------------------------------------------

2.
C preprocessors can have compiler specific features.

A. true
B. false
C. Depends on the standard
D. Depends on the platform

Answer: A

Explanation:
#pragma is compiler specific feature.

----------------------------------------------------------------------------------------------------

3.
C preprocessor is conceptually the first step during compilation

A. true
B. false
C. Depends on the compiler
D. Depends on the standard

Answer: A
-----------------------------------------------------------------------------------------------------

4.
Preprocessor feature that supply line numbers and filenames to compiler is called?

A. Selective inclusion
B. macro substitution
C. Concatenation
D. Line control

Answer: D
-----------------------------------------------------------------------------------------------------

5.
A preprocessor is a program

A. That processes its input data to produce output that is             used as input to another program
B. That is nothing but a loader
C. That links various source files
D. All of the mentioned

Answer: A
-----------------------------------------------------------------------------------------------------

6.
C preprocessor

A. Takes care of conditional compilation
B. Takes care of macros
C. Takes care of include files
D. Acts before compilation
E. None of These

Answer: E
-----------------------------------------------------------------------------------------------------

7.
A preprocessor command

A. need not start on a new line
B. need not start on the first column
C. has # as the first character
D. comes before the first executable statement

Answer: C

----------------------------------------------------------------------------------------------------

More Prepocessor Topics:

Fill The Blanks Preprocessor Questions
Output Preprocessor Questions


100+ Best Home Decoration Ideas For Christmas Day 2019 To Make Home Beautiful

Best gifts for Christmas Day | Greeting cards for Christmas Day | Gift your children a new gift on Christmas day This Christmas d...