1

Is $L = \{A^n B^n C^n \mid n \in \mathbb{N}\}$ a context-free language, e.g. $AAAABBBBCCCC \in L$

If so, what's that context-free grammar that produces it?

Raphael
  • 72,336
  • 29
  • 179
  • 389
  • No, it is not... – MCH Jul 22 '13 at 00:01
  • @MCH Where can I find a proof that it's not? –  Jul 22 '13 at 00:01
  • @MCH (+) does L belong in some specific kind of languages? Thanks :) –  Jul 22 '13 at 00:37
  • 2
    As MCH notes, this language is not context-free, so there's no point looking for a CFG for it. This language is a standard example of a non-context-free language. To show that it isn't context-free, have a look at our reference question, which has all the basic tools, and some examples which are very similar to $L$. Conversely, to determine which class it is in fact in, you need to demonstrate an appropriate grammar or machine that generates it. (cont.) – Luke Mathieson Jul 22 '13 at 08:58
  • (cont.) The Chomsky Hierarchy might be a good place to start looking for where this language might fit. If you haven't reached the higher levels of languages, you may have to wait until you have learnt a bit more before you can completely answer this question. – Luke Mathieson Jul 22 '13 at 09:02
  • On the site-maintenance side of things, as the answer to your question is a simple 'no', I'm going to suggest the question be put on hold so that you can edit it to refine or adjust your question appropriately (remember to try to answer your questions yourself first, and explain where you get stuck - this helps with getting better answers, and with your understanding). This just stops people from posting answers to an unfinished question, and cluttering up the place. When the question is ready again, the question can be reopened for answers. – Luke Mathieson Jul 22 '13 at 09:05
  • 2
    Voting to close. Please check lecture notes on context-free languages, where you will find this example worked out using the pumping lemma. – Yuval Filmus Jul 22 '13 at 12:36
  • 1

0 Answers0