GATE CS 2015, set 3 · Question 44 · Theory of Computation · Multiple choice (MCQ) · 2 marks · −2/3 for a wrong answer

Which of the following languages are context-free?
L₁ = {aᵐ bⁿ aⁿ bᵐ | m, n ≥ 1}L₂ = {aᵐ bⁿ aᵐ bⁿ | m, n ≥ 1}L₃ = {aᵐ bⁿ | m = 2n + 1}

  1. (A) L₁ and L₂ only
  2. (B) L₁ and L₃ only
  3. (C) L₂ and L₃ only
  4. (D) L₃ only
Answer

Answer (B)

Answer from the official GATE CS 2015 answer key.

The step-by-step solution, where available, is part of GATE CS Pro. See what Pro includes