Let πΏ1 and πΏ2 be two languages over a finite alphabet, such that πΏ1 β©πΏ2 and πΏ2 are
regular languages.
Which of the following statements is/are always true?
We are given that \(L_1 \cap L_2\) and \(L_2\) are regular languages, and we need to determine which statement must always hold.
Step 1: Check option (a), 'L1 is regular'. Take \(L_2 = \{\varepsilon\}\) (regular) and \(L_1 = \{\varepsilon\} \cup \{a^n b^n c^n : n \geq 1\}\). Then \(L_1 \cap L_2 = \{\varepsilon\}\), which is regular, so both given conditions hold. But \(L_1\) itself is not regular, since it is not even context-free (by the pumping lemma for context-free languages, a language requiring three simultaneously equal counts cannot be accepted by any pushdown automaton). Hence option (a) fails.
Step 2: Check option (b), 'L1 union L2 is regular'. In the same example, \(L_1 \cup L_2 = L_1\) (since \(\varepsilon\) already belongs to \(L_1\)), which we just showed is not even context-free, so it cannot be regular either. Option (b) fails.
Step 3: Check option (d), 'L1 is context-free'. Using the same counterexample, \(L_1 = \{\varepsilon\} \cup \{a^n b^n c^n : n \geq 1\}\) is not context-free, so option (d) fails as well.
Step 4: Check option (c), 'L2 is context-free'. We are directly told that \(L_2\) is regular. By the Chomsky hierarchy, every regular language is also a context-free language, since a DFA recognizing \(L_2\) can always be treated as a pushdown automaton that never touches its stack. So \(L_2\) being regular guarantees \(L_2\) is context-free, regardless of what \(L_1\) is. This statement is always true, no counterexample can break it.
\[ \text{Regular} \subset \text{Context-Free} \quad \Longrightarrow \quad L_2 \text{ regular} \Longrightarrow L_2 \text{ context-free} \]
Final Answer: option (C), \(L_2\) is context-free.
A schedule of three database transactions \(T_1\), \(T_2\), and \(T_3\) is shown. \(R_i(A)\) and \(W_i(A)\) denote read and write of data item A by transaction \(T_i\), \(i = 1, 2, 3\). The transaction \(T_1\) aborts at the end. Which other transaction(s) will be required to be rolled back?

Which of the following grammars is/are ambiguous?
Consider the following context-free grammar πΊ.
πβππππ΄π΅π΄πππ
π΄βπππ΅π΅π΄π | ππ΅ππππ
π΅βππ΅π | ππ
In the above grammar, π is the start symbol, π and π are terminal symbols, and π΄ and
π΅ are non-terminal symbols.
Let πΏ(πΊ) be the language generated by the grammar πΊ. For a string π βπΏ(πΊ), let
π1(π ) be the number of πβs in π and π2(π ) be the number of πβs in π .
Which of the following statements is/are true?
Consider the following grammar where π is the start symbol, and π and π are
terminal symbols.
π βππππ β£ ππ β£ Ο΅
Which of the following statements is/are true?
Let Ξ£ = {π, π, π, π} and let πΏ= {πππππππββ£π, π, π, ββ₯0}.
Which of the following constraints ensure(s) that the language πΏ is context-free?