Question

Which of the following is a valid token in lexical analysis?

A Syntax error Correct Answer Incorrect Answer
B Variable assignment Correct Answer Incorrect Answer
C Compiler directive Correct Answer Incorrect Answer
D Integer constant Correct Answer Incorrect Answer
E None of these Correct Answer Incorrect Answer

Solution

In lexical analysis, a token is a basic building block of a programming language's syntax. An integer constant, which is a numeric value, is an example of a valid token.

Practice Next

Relevant for Exams:

×
×