0

I have a language L = {a^n b^m c^k | n = m or m != k} When I was working the problem out this is what I got:

S -> S1|S2

S1 -> AC
A -> aAb|$\lambda$
C -> Cc |$\lambda$

S2 -> BD
B -> aB|$\lambda$
D -> bDcc|E
E -> Ecc|$\lambda$

I feel like this is right but at the same time I am not too certain it is. Is this the correct solution?

beroal
  • 781
  • 1
  • 5
  • 12

0 Answers0