Which of the following language is accepted by a Deterministic Pushdown Automata?
Choose an Option
Answer
Any regular language.
Theory
Difference Between DPDA and NPDA
L(DFA) = L(NFA) ⊂ L(DPDA) ⊂ L(NPDA) ⊂ L(LBA) ⊂ L(TM)
- Regular languages [RLs] are accepted by DFA, NFA, DPDA, NPDA, LBA and TM.
- Deterministic context-free languages [DCFLs] are accepted by DPDA, NPDA, LBA and TM. Some DCFLs are not accepted by DFA and NFA.
- Context-free languages [CFLs] are accepted by NPDA, LBA and TM. Some CFLs are not accepted by DFA, NFA and DPDA.
- Context-sensitive languages [CSLs] are accepted by LBA and TM. Some CSLs are not accepted by DFA, NFA, DPDA and NPDA.
- Recursively enumerable languages are accepted by TM. Some RE languages are not accepted by DFA, NFA, DPDA, NPDA and LBA.
Solution
- Option A: Any regular language. --> Correct ✓
- RLs are accepted by DPDA.
- Option B: Any context free language. --> Wrong ✘
- Not all CFLs are accepted by DPDA; only DCFLs are accepted by DPDA.
- Option C: Any language accepted by a non-deterministic pushdown automaton. --> Wrong ✘
- NPDA accepts CFLs, but all CFLs are not accepted by DPDA.
- Option D: Any decidable language. --> Wrong ✘
- DPDA accepts only deterministic context-free languages, not all decidable languages.