In the context-free grammar below, S is the start symbol, a and b are…

GATE · 2006 · IT

In the context-free grammar below, S is the start symbol, a and b are terminals, and ϵ denotes the empty string.


S → aSAb | ϵ

A → bA | ϵ


The grammar generates the language

  1. A.

    ((a + b)* b)*

  2. B.

    {ambn | m ≤ n}

  3. C.

    {ambn | m = n}

  4. D.

    a* b*

Attempted by 50 students.

Show answer

Correct answer: B

The worked solution is available to enrolled students.

Explore the full course: Iocl Engineers Officers Grade A Paper 2

Loading lesson…