There are 40 tokens in this question.
But I have doubt that what should be the wording of the question
"The number of LEXEMES generated by the Lexical Analyzer in the above program is _______ "
OR
"The number of TOKENS generated by the Lexical Analyzer in the above program is _______ "
In most of the question, it is asked about calculating numbers of tokens. Is the answer remains same if they asked about the number of lexemes instead of tokens?
I am confused between these two terms, and I know there are 6 different types of tokens we have namely:-
Keyword, Operators, Identifiers, Constant, Punctuation Symbol and String Constants.
How token and lexeme are different from each other?