All mock tests are FREE till 31 December — register to save your progress
Unit 8 · Theory of Computation and Compilers Paper 2 CS · September 2022

Statement I: CFLs are closed under homomorphism. Statement II: CFLs are closed under complement. Which is correct?

Pick an option to check yourself, or open the answer below.

Show answer & explanation

Correct answer: A. Statement I is true and Statement II is false

Explanation

CFLs are closed under homomorphism (substitute each terminal in the grammar) but not under complement.

More Theory of Computation and Compilers questions