You are on page 1of 1

Name: Nacionales, Iverson B.

Date: October 4, 2022

Course & Section: BSCS-NS-3A Subject: Automata Theory and Formal Language

Activity #1

Instruction: Read Part 1: Chapter 1 – 4 of the book Automata, Computability and Complexity by Elaine
Rich and answer the following Questions.

1. Let 𝐿1 = {𝑎𝑙𝑙 𝑠𝑡𝑟𝑖𝑛𝑔 𝑡ℎ𝑎𝑡 𝑒𝑛𝑑𝑠 𝑖𝑛 𝑎} and 𝐿2 = {𝑎𝑙𝑙 𝑠𝑡𝑟𝑖𝑛𝑔 𝑡ℎ𝑎𝑡 𝑠𝑡𝑎𝑟𝑡𝑠 𝑖𝑛 𝑏} for Σ = {𝑎, 𝑏}
Find the following language. (1 point each)
a. 𝐿2 𝐿1 = { 𝜀, ba, baa, baaa, bbbaa, bba, bbaa, bbaaa, bbbbaa, bbba}
b. ¬(𝐿2 ) = { 𝜀, a, aa, aaa, aaaa, …all strings that does not starts in b}
c. ¬(𝐿1 ) = { 𝜀, b, bb, bbb, bbbb, …all strings that does not end in a}
d. 𝐿1 ∩ 𝐿2 = { 𝜀 }
e. 𝐿1 ∪ 𝐿2 = { 𝜀, a, aa, aaa, bbaa, ba, b, bb, bbb}

2. Let 𝐿 = {𝑒𝑣𝑒𝑛 𝑛𝑢𝑚𝑏𝑒𝑟𝑠 𝑜𝑓 𝑎′ 𝑠 𝑎𝑛𝑑 𝑏′𝑠}. For each of the following strings, state whether it is
an element of 𝐿. (1 point each)
a. ababababaa - no
b. aabbaabbaa - yes
c. aabbcc - no
d. baabaabaabbb - no
e. 𝜀 - yes

3. Let 𝐿 = {𝑢𝑝, 𝑑𝑜𝑤𝑛, 𝑟𝑖𝑔ℎ𝑡, 𝑙𝑒𝑓𝑡}. List the element of 𝐿2 𝑜𝑟 𝐿𝐿 in lexicographic order. (5 points)
Ans: {upup, updown, upleft, upright, downup, downdown, downleft, downright, leftup,
leftdown, leftright, leftleft, rightup, rightdown, rightleft, rightright}

You might also like