3 votes 3 votes I have gone through this link and found that both are synonyms to each other but I am not getting that when we have more than one parse tree for a string so do we say that the grammar is ambiguous since in the parse tree we haven't mentioned whether it is a left-most-derivation tree or right-most-derivation tree and we say that for a grammar to be unambiguous we should have a unique left-most derivation tree and unique right-most derivation tree . http://stackoverflow.com/questions/5729961/any-differences-between-terms-parse-trees-and-derivation-trees Compiler Design compiler-design parsing + – radha gogia asked Dec 6, 2015 • retagged Jun 17, 2022 by Lakshman Bhaiya radha gogia 2.5k views answer comment Share Follow See all 11 Comments See all 11 11 Comments reply Show 8 previous comments Praveen Saini commented Dec 7, 2015 reply Follow Share if a grammar derives one string with left derivation as well as right derivation then it is ambiguous , if both left and right derivation correspond to 2 different parse trees 1 votes 1 votes radha gogia commented Dec 7, 2015 reply Follow Share Sir plz see this question ,here first option is marked false , and as u said that if they have same left-most derivation and right-most derivation then the grammar is unambiguous , https://gateoverflow.in/711/gate2001_1-18 1 votes 1 votes Praveen Saini commented Dec 7, 2015 reply Follow Share Recheck there is nothing given about corresponding trees. if don't have two different (looking) tree, we can't say it is ambiguous. 1 votes 1 votes Please log in or register to add a comment.
1 votes 1 votes Both derivation tree and parse tree are same. The tree made for each derivation (right most or left most) would be the same. So, for an unambiguous grammar be have a single parse/derivation tree. monanshi answered Dec 6, 2015 monanshi comment Share Follow See all 3 Comments See all 3 3 Comments reply radha gogia commented Dec 6, 2015 reply Follow Share Would like to add one point for an unambiguous grammar u may have more than one parse tree since left-most derivation tree and right-most derivation tree are two different parse trees and for an unambiguous grammar we have a unique left-most derivation tree and unique right-most derivation tree . 0 votes 0 votes monanshi commented Dec 7, 2015 reply Follow Share For ambiguous, we will have more than one parse tree. (for sure) 0 votes 0 votes Prateek kumar commented Sep 2, 2016 reply Follow Share for any particular string let's say "w":- number of parse tree = number of LMD = number of RMD 0 votes 0 votes Please log in or register to add a comment.