1 votes 1 votes How to represent array expressions using DAG? for example a=b[i]+c[j] how to represent this using DAG? Compiler Design syntax-directed-translation compiler-design + – aditi19 asked Mar 31, 2019 edited Apr 3, 2019 by aditi19 aditi19 1.4k views answer comment Share Follow See all 7 Comments See all 7 7 Comments reply srestha commented Mar 31, 2019 reply Follow Share syntax tree represented by terminals and symbols For that we need the grammar first. I mean what is syntax directed definition here? 0 votes 0 votes aditi19 commented Mar 31, 2019 reply Follow Share why do we need SDD here? I'm asking how to represent this expression using syntax tree 0 votes 0 votes ankitgupta.1729 commented Mar 31, 2019 reply Follow Share if you mean expression tree then it will be like this :- In-order traversal of an expression tree gives infix notation which is mentioned in the question. 0 votes 0 votes srestha commented Mar 31, 2019 reply Follow Share @ankitgupta.1729 is $b\left [ i \right ]$ and $c\left [ j \right ]$ is in terminal form? Then how r u making syntax tree for it? 0 votes 0 votes srestha commented Apr 3, 2019 reply Follow Share @aditi19 @ankitgupta.1729 $b\left [ i \right ]+$ cannot be parse to a grammar, because it is not a handle So, parse tree is not possible with it ok ?? 0 votes 0 votes ankitgupta.1729 commented Apr 3, 2019 reply Follow Share mam, as you said for parse tree , we need grammar which is not given in question. 1 votes 1 votes aditi19 commented Apr 3, 2019 reply Follow Share sorry! it'll be DAG.. not syntax tree... I'm updating the question 0 votes 0 votes Please log in or register to add a comment.