Parsing

Parsing

University

12 Qs

quiz-placeholder

Similar activities

Syntax Testing

Syntax Testing

University

10 Qs

Predictive Parser

Predictive Parser

University - Professional Development

10 Qs

Compiladores - U1 S3

Compiladores - U1 S3

University

10 Qs

CD VIVA

CD VIVA

University - Professional Development

10 Qs

QUIZ CD S5 7-4-22

QUIZ CD S5 7-4-22

University

10 Qs

Compiler Design I

Compiler Design I

University

15 Qs

CFG - Quiz Review

CFG - Quiz Review

University - Professional Development

11 Qs

Parsing

Parsing

Assessment

Quiz

Computers

University

Medium

Created by

Akashdeep Sharma

Used 16+ times

FREE Resource

12 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

Which of the following lexical entries can be derived from <word>

I. pick

II picks

III c44

I, II AND III

I and II only

I and III only

II and III only

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

A bottom up parser generates __________.

Right most derivation

Rightmost derivation in reverse

Leftmost derivation

Leftmost derivation in reverse

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Shift reduce parsers are __________.

Top down Parser

Bottom Up parser

May be top down or bottom up

None of the mentioned

4.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Which of the following describes a handle (as applicable to LR-parsing) appropriately?

Position where next reduce or shift operation will occur

The next step has use of Non-terminal for reduction

Used for reduction in a coming-up step along with a position in the sentential form where the next shift or reduce operation will occur

Used in the next step for reduction along with a position in the sentential form where the right hand side of the production may be found

5.

MULTIPLE SELECT QUESTION

45 sec • 1 pt

Consider the grammar defined by the following production rules:

S --> T * P

T --> U | T * U

P --> Q + P | Q

Q --> Id

U --> Id

Which one of the following is TRUE?

+ is left associative, while ∗ is right associative

+ is right associative, while ∗ is left associative

Both + and ∗ are right associative

Both + and ∗ are left associative

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following grammar rules violate the requirements of an operator grammar?

(i) P -> QR

(ii) P -> QsR

(iii) P -> ε

(iv) P -> QtRr

(i) only

(i) and (iii) only

(ii) and (iii) only

(iii) and (iv) only

7.

MULTIPLE SELECT QUESTION

45 sec • 1 pt

Which of the following actions an operator precedence parser may take to recover from an error?

Delete symbols from the stack

Insert symbols onto the stack

Inserting or deleting symbols from the input

Stop the parsing

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?