Macro & Preprocessor in C

11. What is a preprocessor directive

A. a message from compiler to the programmer
B. a message from programmer to the preprocessor
C. a message from programmer to the microprocessor
D. a message from compiler to the linker

View Answer


12. Which of the following are correctly formed #define statements?

A. #define INCH PER FEET 12
B. #define SQR(X) (X *X);
C. #define SQR(X) X*X
D. #define SQR(X) (X*X)

View Answer


13. A macro must always be written in capital letters.

A. True
B. False

View Answer


14. A macro should always be accommodated in a single line.

A. True
B. False

View Answer


15. After preprocessing when the program is sent for compilation the macros are removed from the expanded source code.

A. True
B. False

View Answer


16. Macros with arguments are not allowed.

A. True
B. False

View Answer


17. Nested macros are allowed.

A. True
B. False

View Answer


18. Tn a macro call the control is passed to the macro.

A. True
B. False

View Answer


19. All macro substitutions in a program are done?

A. Before compilation of the program.
B. After compilation
C. During execution
D. None of the above

View Answer


20. In a program the statement:
    #include "filename"
is replaced by the contents of the file "filename"?

A. Before compilation
B. After Compilation
C. During execution
D. None of the Above

View Answer






Also check :


Discussion


* You must be logged in to add comment.