Solution: Option (B)
Solution: Option (B)
Solution: Option (B)
S aB | aAb
A bAb | a
B aB |
How many back tracks are required to generate the string aab from the above grammar?
(a) 1 (b) 2
(c) 3 (d) 4
Solution: Option (b)
5. S Sa | b
Which of the following is True?
(a) There will be SR conflict during parsing
(b) There will be RR conflict during Parsing
(c) There will be both conflict
(d) There will be no conflict
Solution: Option (d)
10. Which of the following comments about peep-hole optimization are True?
(a) It is applied to a small part of the code
(b) It can be used to optimize intermediate code
(c) It can be applied to a portion of the code that is not contiguous
(d) All of the above
Solution: Option (d)
11. In a syntax directed translation scheme, if the value of an attribute of a node is a function
of the values of the attributes of its children, then it is called a
(a) synthesized attribute (b) inherited attribute
(c) canonical attribute (d) none of the above
Solution: Option (a)