Question discussion

Which of the following lists the phases of a compiler in the correct order?

1738Medium DSSSB TGT Computer Science 0 replies 1 views
0

Which of the following lists the phases of a compiler in the correct order?

  • ASyntax analysis, lexical analysis, semantic analysis, code generation, intermediate code generation
  • BLexical analysis, syntax analysis, semantic analysis, intermediate code generation, code generation
  • CLexical analysis, semantic analysis, syntax analysis, code generation, intermediate code generation
  • DCode generation, lexical analysis, syntax analysis, semantic analysis, intermediate code generation
Correct answer: B

Explanation

A compiler first breaks the source into tokens, then parses them, checks their meaning, produces intermediate code and finally generates target code.

Discussion 0

Nobody has replied yet. Start the discussion!