Question: The languages L 1 = {a n b m | m = n or m = 2n } and L 2 = {a n b
The languages L1 = {anbm | m = n or m = 2n } and L2 = {a n b m | n <= m <= 2n } are context free.
a. Choose one of the languages and write a CFG for it.
b. Write the PDA that comes from your grammar (part a). Show the first 4 moves it would make on some string in your language (of length at least 4). Be sure to show state, input, and stack at each move.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
