Test: Lexical Analysis- 2


Test Description

15 Questions MCQ Test GATE Computer Science Engineering(CSE) 2023 Mock Test Series | Test: Lexical Analysis- 2

Test: Lexical Analysis- 2 for Computer Science Engineering (CSE) 2022 is part of GATE Computer Science Engineering(CSE) 2023 Mock Test Series preparation. The Test: Lexical Analysis- 2 questions and answers have been prepared according to the Computer Science Engineering (CSE) exam syllabus.The Test: Lexical Analysis- 2 MCQs are made for Computer Science Engineering (CSE) 2022 Exam. Find important definitions, questions, notes, meanings, examples, exercises, MCQs and online tests for Test: Lexical Analysis- 2 below.
Solutions of Test: Lexical Analysis- 2 questions in English are available as part of our GATE Computer Science Engineering(CSE) 2023 Mock Test Series for Computer Science Engineering (CSE) & Test: Lexical Analysis- 2 solutions in Hindi for GATE Computer Science Engineering(CSE) 2023 Mock Test Series course. Download more important topics, notes, lectures and mock test series for Computer Science Engineering (CSE) Exam by signing up for free. Attempt Test: Lexical Analysis- 2 | 15 questions in 45 minutes | Mock test for Computer Science Engineering (CSE) preparation | Free important questions MCQ to study GATE Computer Science Engineering(CSE) 2023 Mock Test Series for Computer Science Engineering (CSE) Exam | Download free PDF with solutions
1 Crore+ students have signed up on EduRev. Have you?
Test: Lexical Analysis- 2 - Question 1

In a two pass assembler pseudo code EQU is to be evaluated during

Detailed Solution for Test: Lexical Analysis- 2 - Question 1

In 2-pass assembler during pass-1 pseudo code EQU is to be evaluated.

Test: Lexical Analysis- 2 - Question 2

Pick the functions which are completely performed in pass 1

Detailed Solution for Test: Lexical Analysis- 2 - Question 2

Operation performed during pass-1 in 2-pass compiler:
1. Processing the DB pseudo-op.
2. Updating the location counter.
3. Processing of EQU pseudo-op.
4. Processing of DS pseudo-op.

Test: Lexical Analysis- 2 - Question 3

in a context-free grammar

Detailed Solution for Test: Lexical Analysis- 2 - Question 3

The context free grammar is represented as
S → X

where S∈ V(Single symbol non-terminal)

D → (V ∪ T ) * (Any number of terminal and nonterminals)

Test: Lexical Analysis- 2 - Question 4

If two finite state machines M and N are isomorphic, then

Test: Lexical Analysis- 2 - Question 5

In an incompletely specified automata

Detailed Solution for Test: Lexical Analysis- 2 - Question 5

In incomplete automata some states have no transition on some tokens.

Test: Lexical Analysis- 2 - Question 6

Consider the following issues:
1. Simplify the phases.
2. Compiler efficiency is improved.
3. Compiler works faster.
4. Compiler portability is enhanced.

Which is/are true in context of lexical analysis?

Detailed Solution for Test: Lexical Analysis- 2 - Question 6

Lexical analysis consists of the phases that
(i) Simplify the subsequent phases by the help of tokens instead of arbitrary elements.
(ii) Since interrelated elements are converted to stream of tokens hence compiler efficiency is improved as no arbitrary storage or value is to be checked independently.
(iii) Computer portability is enhanced.

Test: Lexical Analysis- 2 - Question 7

Which of the following is not generated by the grammar G?

Detailed Solution for Test: Lexical Analysis- 2 - Question 7

Test: Lexical Analysis- 2 - Question 8

Given two DFA’s M1, and M2. They are equivalent if

Detailed Solution for Test: Lexical Analysis- 2 - Question 8

Given two DFA’s M1 and M2. They are equivalent if the language generated by them is same i,e, L(M1) = L(M2)

Test: Lexical Analysis- 2 - Question 9

For the string aabbaa give the derivation tree using grammar:

G = {{S, A}, {a, b}, {S → aAS, S→ a, A → SbA, A→  SS, A → ba}, S}

Detailed Solution for Test: Lexical Analysis- 2 - Question 9

S → aAS, S→ a, A → SbA, A→  SS, A → ba}, S

Input: aabbaa

Test: Lexical Analysis- 2 - Question 10

Consider a program P that consists of two source modules M1 and M2 contained in two different files. If M1 contains a reference to a function defined in Mthe reference will be resolved at

Detailed Solution for Test: Lexical Analysis- 2 - Question 10

Modules may be compiled separately and all linking between references is made at link time.

Test: Lexical Analysis- 2 - Question 11

Consider line number 3 of the following C-program.
int main ()  { /* Line 1 */ 
int i, n; /* Line 2 */
fro (i = 0, i < n, /+ + ); /* Line 3 */
}

Identify the compiler’s response about this line while creating the object - module

Detailed Solution for Test: Lexical Analysis- 2 - Question 11

Error is underlined function fro()
Which is a syntactical error rather than lexical.

Test: Lexical Analysis- 2 - Question 12

Consider the following grammars:

Which of the following statements is not true?

Detailed Solution for Test: Lexical Analysis- 2 - Question 12

Here grammar, G2 is not ambiguous 

Because there exist only one parse tree.

Test: Lexical Analysis- 2 - Question 13

Hash tables can contribute to an efficient average case solution for all of the following problems described below except

Detailed Solution for Test: Lexical Analysis- 2 - Question 13

Hash table can contribute to an efficient average case solution for symbol table look up problem

Test: Lexical Analysis- 2 - Question 14

Consider the grammar:

Which of the following sentence can be derived by this grammar?

Detailed Solution for Test: Lexical Analysis- 2 - Question 14

S — ABc — abc

Test: Lexical Analysis- 2 - Question 15

Which of the following is not a regular grammars?
 

Detailed Solution for Test: Lexical Analysis- 2 - Question 15

Mixup notation of left linear and right linear grammar is not allowed in regular grammar.

Use Code STAYHOME200 and get INR 200 additional OFF
Use Coupon Code
Information about Test: Lexical Analysis- 2 Page
In this test you can find the Exam questions for Test: Lexical Analysis- 2 solved & explained in the simplest way possible. Besides giving Questions and answers for Test: Lexical Analysis- 2, EduRev gives you an ample number of Online tests for practice