Consider the following statements.
- If is regular, then both and must be regular.
- The class of regular languages is closed under infinite union.
Which of the above statements is/are TRUE?
View worked solution
Answer: D
We analyze the two statements individually:
Statement I: If is regular, then both and must be regular.
This statement is FALSE. We can show this using a counterexample:
- Let , which is a well-known non-regular language.
- Let , which is also non-regular (since the complement of a regular language is regular, if were regular, would have to be regular).
- Their union is , which is a regular language.
Since is regular but neither nor is regular, Statement I does not hold.
Statement II: The class of regular languages is closed under infinite union.
This statement is FALSE. Regular languages are closed under finite union, but not necessarily under infinite union. We can show this using a counterexample:
- Let . For each , define the language .
- Each contains exactly one string, making it a finite language, and therefore regular.
- The infinite union of these languages is:
- The language is not regular (which can be proven using the pumping lemma, as the spacing between consecutive string lengths increases monotonically).
Since the infinite union of regular languages can result in a non-regular language, Statement II does not hold.
Thus, both Statement I and Statement II are false.
Free practice · Your answers on this page are not saved.
