Computer Sciences > Gate 2016 Set-1 > SDT
Consider the following Syntax Directed Translation Scheme (SDTS), with non-terminals
{S, A} and terminals {a, b}.
Using the above SDTS, the output printed by a bottom-up parser, for the input aab is:
S −→ aA { print 1 }
S −→ a { print 2 }
A −→ Sb { print 3 }
S −→ a { print 2 }
A −→ Sb { print 3 }
Using the above SDTS, the output printed by a bottom-up parser, for the input aab is:
Explanation
Correct : SDT
Similar Questions
What is the worst-case time complexity of insertion in an AVL tree?
Which operations on a binary search tree have O(h) complexity?
Compare search complexities of sorted array vs balanced BST.