3 votes 3 votes A given grammar is called ambiguous if two or more productions have the same non-terminal on the left hand side a derivation tree has more than one associated sentence there is a sentence with more than one derivation tree corresponding to it brackets are not present in the grammar Compiler Design isro-2020 compiler-design ambiguous-grammar easy + – Satbir asked Jan 13, 2020 • retagged Dec 4, 2022 by Lakshman Bhaiya Satbir 9.0k views answer comment Share Follow See 1 comment See all 1 1 comment reply HiteshVaish commented Jul 7, 2020 reply Follow Share A grammar is ambiguous if and only if a sentence have two or more derivation trees so option C is correct 0 votes 0 votes Please log in or register to add a comment.
3 votes 3 votes $\underline{\mathbf{Answer:}\Rightarrow}\;\mathbf{c.}$ A grammar is said to be ambigous if there exists more than one derivation tree of the given grammar, i.e., more than one LMD or RMD. https://www.geeksforgeeks.org/ambiguous-grammar/ `JEET answered Jan 13, 2020 • edited Jan 13, 2020 by `JEET `JEET comment Share Follow See all 0 reply Please log in or register to add a comment.
1 votes 1 votes A grammar is said to be ambiguous if it can produce more than one parse tree for a particular sentence; this occurs when two different sequences of leftmost (or rightmost) derivations can produce the same sentence from the same start symbol. Reference: https://cs.uwaterloo.ca/~cbruni/CS241Resources/lectures/2019_Winter/CS241L10_cfg_ambiguity_top_down_parsing_post.pdf https://www.cas.mcmaster.ca/~zucker/2f/2fno/5b.pdf https://www.d.umn.edu/~rmaclin/cs5641/Notes/Lecture6.pdf https://www.univ-orleans.fr/lifo/Members/Mirian.Halfeld/Cours/TLComp/res2-CG.pdf So, the correct answer is $(C).$ Lakshman Bhaiya answered Jan 13, 2020 • edited Dec 5, 2023 by Lakshman Bhaiya Lakshman Bhaiya comment Share Follow See all 3 Comments See all 3 3 Comments reply AniMan_7 commented Dec 4, 2023 reply Follow Share @Lakshman Bhaiya bhaiya the reference slide link is not working, can you please resend if possible, or any other standard source regarding different definition of ambiguity. 1 votes 1 votes Lakshman Bhaiya commented Dec 5, 2023 reply Follow Share @AniMan_7 I have updated the links. 2 votes 2 votes AniMan_7 commented Dec 5, 2023 reply Follow Share thanks a lot bhaiya. 1 votes 1 votes Please log in or register to add a comment.
1 votes 1 votes option C for a string it has more than one parse tree pritambiswas000007 answered Jun 9, 2020 pritambiswas000007 comment Share Follow See all 0 reply Please log in or register to add a comment.
0 votes 0 votes option C) is the correct answer, A grammar is said to be ambiguous if for a string it is having more than one parse tree. Sanandan answered Sep 14, 2020 Sanandan comment Share Follow See all 0 reply Please log in or register to add a comment.