Re: Exercise 2.1.2 from Aho&Ulman The theory of Parsing textbook?



Tegiri Nenashi <TegiriNenashi@xxxxxxxxx> writes:

"Construct CFG that generates all strings having equal number of a's
and b's"

My attempt:

X = 1 + aXa + aaX +Xaa + bXb + Xbb +bbX +YY
Y = 1 + (a+b)Y

I don't know this notation, but I can't find an assignment of symbols
to meanings that makes this a solution! What do you mean by these
symbols?

--
Ben.
.



Relevant Pages

  • Re: The "()" operator revisited.
    ... part procedure call and part assignment statement. ... whole new language construct (something based Reverse Polish Notation ... easier to handle than trying to remold array notation. ... its not the dress that makes you look fat. ...
    (comp.lang.ada)
  • Re: A MOD B NO MATH HAHAHAHA !!
    ... I know _exactly_ what the problem is with the notation, ... And David Ullrich for another. ... I'm aware, and now more than eer, of the different meanings of mod, ... with or without parentheses, in mathematics and ...
    (sci.math)
  • Assignment of var without escape/interpolation
    ... chomp $str; ... IMO this is no assignment of a var anymore. ... box with here-doc and chomp. ... But this notation is not very parctical to use in daily work (eg ...
    (comp.lang.perl.misc)
  • Re: Regular expressions
    ... > I am studying Computer Science and we are currently covering regexps in ... it's definitely not Perl notation. ... assignment. ...
    (comp.lang.perl.misc)
  • Re: Dissecting privileges, Chapter 1: giving up PA.
    ... terms of assignment. ... relinquish privilege awareness before making the following privilege ... the same notation which means conceptual equivalence above is ... Obviously, this is very confusing. ...
    (comp.unix.solaris)