GATE CSE Lexical & Syntax Analysis – Compiler Design | Set 1

Questions 1-5 of 100

0% completed (0/100 answered)
Your score 0/100 0 answered
Correct 0 Incorrect 0 Unanswered 100 Accuracy 0%

Question 1

MCQ · Single Correct 1 mark

In a compiler, the phase that converts a stream of characters into a stream of meaningful tokens is called:

Answers for question 1

Question 2

MCQ · Single Correct 1 mark

Consider the C code statement: printf("i = %d, &i = %x", i, &i); How many tokens are present in this statement?

Answers for question 2

Question 3

MCQ · Single Correct 1 mark

In a C compiler, which phase handles preprocessor directives such as #define and #include?

Answers for question 3

Question 4

MCQ · Single Correct 1 mark

Which formal language model can recognize the regular languages typically used to specify lexical token patterns?

Answers for question 4

Question 5

MCQ · Single Correct 1 mark

Which compiler phase detects type mismatch errors, such as assigning a float value to a pointer variable without casting?

Answers for question 5
Scroll to Top