Open In App

GATE | GATE 2017 MOCK II | Question 58

Last Updated : 28 Jun, 2021
Like Article
Like
Save
Share
Report

Consider the following SDT

    S -> 1A23    {print “GA”}
    A -> 4S        {print “TE”}
    A -> 5        {print “C”}
    A -> B        {print “SE”}
    B -> 6B        {print “TE”}
    B -> 2        {print “ST”}

What will be output by the SDT for the input string “14122323”?
(A) GATEGASEST
(B) STSEGATEGA
(C) STGASETEGA
(D) GASTSEGATE


Answer: (B)

Explanation: sdt

Quiz of this Question


Like Article
Suggest improvement
Previous
Next
Share your thoughts in the comments

Similar Reads