Pushdown automata can recognize language generated by_________.
2018
Pushdown automata can recognize language generated by_________.
- A.
Only context free grammar
- B.
Only regular grammar
- C.
Context free grammar or regular grammar
- D.
Only context sensitive grammar
Attempted by 151 students.
Show answer & explanation
Correct answer: C
Key idea: A pushdown automaton (PDA) recognizes exactly the class of context-free languages.
PDAs handle nonregular context-free languages by using the stack to track nested or balanced structures (for example, the language of strings of the form a^n b^n).
Every regular language is also context-free, so a PDA can recognize regular languages too. A PDA can simulate a finite automaton by not using the stack or by using it in a trivial way.
Conclusion: Pushdown automata recognize languages generated by context-free grammars; because regular grammars generate languages that are a subset of context-free languages, pushdown automata also recognize those regular languages.
A video solution is available for this question — log in and enroll to watch it.