Re: Problem with top down parsing

"Ujjwal" <ujjwal.konar@gmail.com>
22 Nov 2006 21:17:50 -0500

          From comp.compilers

Related articles
Problem with top down parsing anandr86@gmail.com (2006-10-24)
Re: Problem with top down parsing ujjwal.konar@gmail.com (Ujjwal) (2006-11-22)
Re: Problem with top down parsing adrian@cs.rhul.ac.uk (A Johnstone) (2006-11-24)
Re: Problem with top down parsing schmitz@i3s.unice.fr (Sylvain Schmitz) (2006-11-24)
| List of all articles for this month |

From: "Ujjwal" <ujjwal.konar@gmail.com>
Newsgroups: comp.compilers
Date: 22 Nov 2006 21:17:50 -0500
Organization: Compilers Central
References: 06-10-094
Keywords: parse
Posted-Date: 22 Nov 2006 21:17:50 EST

Hi,


I think 'top down parsing with backtracking' can also produce 6 a's by
menas of the following way:


S -> aSa -> aaSaa (using the production S -> aSa)
                            -> aaaaaa (using the production S -> aa)


Please correct me in case I missed anything.


With best regards,
Ujjwal.


anandr86@gmail.com wrote:
> Hi,
> In the book "Principles of compiler design, Aho Ullman" the
> following exercise caught my attention. The grammar given is
>
> S -> aSa | aa
>
> It is quoted that a "top down parse with backtracking" can establish
> the inputs with 2,4 or 8 a's but not 6 a's .... How is this possible ?


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.