Computer Science Fundamentals Algorithms Objective
Feb 15, 2013

A shift reduce parser carries out the actions specified within braces immediately after reducing with the corresponding rule of grammer

S----> xxW ( PRINT "1")

S----> y { print " 2 " }

S----> Sz { print " 3 " )

What is the translation of xxxxyzz using the syntax directed translation scheme described by the above rules ?

Choose the correct answer:
A) 23131
B) 11233
C) 11231
D) 33211
Detailed Explanation

Option a is right answer.

Discussion (0)

No comments yet. Be the first to share your thoughts!

Share Your Thoughts
Feedback