Skip to content
Official PYQ · 1995

GATE CS 1995 Q1.11 — Lexical Analysis

Explain with AI

What are xx and yy in the following macro definition?

macro	Add x, y
        Load y
        Mul x
        Store y
end macro	
Choose one option
View worked solution

Answer: D

In a macro definition, the placeholders specified in the header are called formal parameters (or dummy arguments).

In the given macro definition:

macro Add x, y
      Load y
      Mul x
      Store y
end macro

Here, xx and yy are placeholders that will be replaced by real arguments during macro expansion. Therefore, they are formal parameters.

When the macro is invoked (for example, Add A, B), the arguments AA and BB provided at the call site are known as the actual parameters.

Free practice · Your answers on this page are not saved.

Published
Report a correction
Keep exploringMore Lexical Analysis questions