in Compiler Design retagged by
1,917 views
2 votes
2 votes

In a compiler, keywords of a language are recognized during

  1. parsing of the program
  2. the code generation
  3. the lexical analysis of the program
  4. dataflow analysis
in Compiler Design retagged by
by
1.9k views

5 Answers

2 votes
2 votes
option C

In programming language, keywords, constants, identifiers, strings, numbers, operators and punctuations symbols can be considered as tokens in lexical analysing phase.
0 votes
0 votes
Lexical analysis is the first phase of a compiler. It takes the modified source code from language preprocessors that are written in the form of sentences. The lexical analyzer breaks these syntax into a series of tokens, by removing any white space or comments in the source code.

If the lexical analyzer finds a token invalid, it generates an error. The lexical analyzer works closely with the syntax analyzer. It reads character streams from the source code, checks for legal tokens, and passes the data to the syntax analyzer when it demands.

In programming language, keywords, constants, identifiers, strings, numbers, operators and punctuations symbols can be considered as tokens.
0 votes
0 votes
answer:- (c)

in a compiler keywords of a language are recognized during the lexical analysis of the program.
0 votes
0 votes
As lexical analyzer scans character by character through whole source program and according to maximum munch rule it identifies the keywords and set of tokens

So option is C
Answer:

Related questions