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

Let A = {a, b} and L = A*. Let X = {aⁿbⁿ | n > 0}. The languages L ∪ X and X are respectively:

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

Show answer & explanation

Correct answer: C. Regular, Not regular

Explanation

X ⊆ A*, so L ∪ X = A*, which is regular. X = aⁿbⁿ is the classic non-regular language.

More Theory of Computation and Compilers questions