Multiple choice

Which of the following is a similarity between macro processor and compiler pre-processor?

  1. Functionally, both are same.

  2. Both are used to preprocesse the assembler directives.

  3. Both are used to preprocess the compiler directives.

  4. Both provide subroutine facility to language processor.

  5. Both are different, they do not have any similarity.

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

Both processes are performed before the actual conversion of source program is done. Macro processor puts the actual assembly code in place of Macro symbol, wherever these are used or defined. Compiler pre processor preprocesses the header files and other predefined terms.