1. Trang chủ
  2. » Công Nghệ Thông Tin

Tutorial 3

1 1 0

Đang tải... (xem toàn văn)

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 1
Dung lượng 10,28 KB

Nội dung

Tutorial3 doc TUTORIAL 3 1 Consider the following grammar E à T+E | T T à id a Construct the collection of sets of LR(0) items for this grammar b Construct the parsing table using SLR method c Show th[.]

TUTORIAL Consider the following grammar E T+E | T T id a Construct the collection of sets of LR(0) items for this grammar b Construct the parsing table using SLR method c Show the moves according to the table constructed above on the inputs of id+id and id+id+id Show that the following grammar is LL(1) but not SLR(1) Also, show that the grammar is LR(1) as well S AaAb | BbBa Aà∈ Bà∈ Hint: Note that S •∈ is concurrently equivalent to S ∈•, or we can write S • Show that the following grammar is LR(1) but not SLR(1) S Aa | bAc | dc | bda Aàd Show that the following grammar is LR(1) but not LALR(1) S As | bAc | Bc | bBa Aàd Bàd PDF created with pdfFactory Pro trial version www.pdffactory.com

Ngày đăng: 11/04/2023, 11:05

w