You are on page 1of 2

Format No.: MITAOE/ACAD/INST/12/A Rev.No.: 02 Rev.

Date:1/1/2023

ASSIGNMENT
( An Autonomous Institute Affiliated to SPPU) ACADEMIC YEAR 2022-2023
Alandi (D), Pune – 412105 SEMESTER VI
CLASS &
SCHOOL OF COMPUTER ENGG. TY A, B, & C
DIVISION

COURSE CODE CS 348 ASSIGNMENT NO. 02

COURSE Compiler Design DATE 20-03-2023

Que. CO RBT
Question Description Marks
No. No. Level

Construct the predictive parsing table for the following


grammar , where S’ is the start symbol and # is the end
marker
S’->S#
S->qABC
1. 5 CO3 L3
A-> a | bbD
B-> a | 
C-> b |
D-> c | 

Distinguish between Top down and Bottom up parsing


based on the following
2. 1. Working 5 CO3 L2
2. Type of grammar used
3. Stack Implementation

Prepare cannonical collections of LR(0) items and parsing


table for the following grammar.
3. S-> L= R | R 5 CO3 L3
L-> *R | id
R-> L

Construct an LALR Parsing Table for the following


grammar
4. 5 CO3 L3
S-> Aa |bAc |dc |bda
A->d

(Remark: Course Instructor to add assessment rubrics for each assignment)

1
Format No.: MITAOE/ACAD/INST/12/A Rev.No.: 02 Rev.Date:1/1/2023

Good(4-5) Average(2-3) Poor(0-2)


Question1 Correct FIRST & Correct FIRST & Correct FIRST &
FOLLOW SETS, FOLLOW SETS, FOLLOW SETS,
Parsing Table with Parsing Table with Parsing Table with
all Correct entries all Correct entries all Correct entries
with one or two with more than 2
mistakes mistakes
Question2 Working -1 mark
2 marks each for
remaining two
Question3 Correct Cannoical Correct Cannoical Correct Cannoical
collection of LR(0) collection of LR(0) collection of LR(0)
items, correct items with one or items with more
parsing table two mistakes than two mistakes
Question4 Correct Cannoical Correct Cannoical Correct Cannoical
collection of LALR collection of LALR collection of LALR
items, correct items with one or items with more
parsing table two mistakes than two mistakes

Kavitha S
20-03-2023
Course Teacher
Name and Sign with Date

You might also like