Skip to main content
added 56 characters in body
Source Link
Yuval Filmus
  • 279.1k
  • 27
  • 316
  • 512

Your language consists of all words over $\{a,b\}$ which contain $a$. This is a regular language, and so it has aan unambiguous regular grammar, - essentially a DFA - which is not so difficult to construct for this language. Regular grammars constructed from DFAs are unambiguous, so this would be an unambiguous grammar for the same language.

Your language consists of all words over $\{a,b\}$ which contain $a$. This is a regular language, and so it has a regular grammar, which is not so difficult to construct for this language. Regular grammars are unambiguous, so this would be an unambiguous grammar for the same language.

Your language consists of all words over $\{a,b\}$ which contain $a$. This is a regular language, and so it has an unambiguous regular grammar - essentially a DFA - which is not so difficult to construct for this language. Regular grammars constructed from DFAs are unambiguous, so this would be an unambiguous grammar for the same language.

Source Link
Yuval Filmus
  • 279.1k
  • 27
  • 316
  • 512

Your language consists of all words over $\{a,b\}$ which contain $a$. This is a regular language, and so it has a regular grammar, which is not so difficult to construct for this language. Regular grammars are unambiguous, so this would be an unambiguous grammar for the same language.