GATE CSE
First time here? Checkout the FAQ!
x
0 votes
37 views

Consider the following grammar :
S →(S) | ε
Consider an instant where while parsing the string “(())”
Top of stack: S
Input pointer: )
image:AGT10/36.png
The operation performed at this point is?

  1.   S is popped off
  2.   S is kept as it is.
  3.   S is kept as it is and the input pointer is incremented
  4.   None of these.
asked in Compiler Design by Active (1.3k points)   | 37 views

The  LL(1) table is :

  ( ) $
S S->(S) S->$\epsilon$ S->$\epsilon$

So, with this , option 1 seems appropriate.

Please log in or register to answer this question.

Related questions

0 votes
1 answer
1
asked in Compiler Design by sudhirnayak (11 points)   | 71 views
0 votes
1 answer
2
0 votes
1 answer
3
asked in Compiler Design by Null&Void Active (1.9k points)   | 49 views


Top Users May 2017
  1. akash.dinkar12

    3154 Points

  2. pawan kumarln

    1636 Points

  3. sh!va

    1590 Points

  4. Arjun

    1350 Points

  5. Bikram

    1298 Points

  6. Devshree Dubey

    1246 Points

  7. Angkit

    1044 Points

  8. Debashish Deka

    1042 Points

  9. LeenSharma

    880 Points

  10. srestha

    706 Points

Monthly Topper: Rs. 500 gift card
Top Users 2017 May 22 - 28
  1. Bikram

    384 Points

  2. pawan kumarln

    262 Points

  3. Ahwan

    236 Points

  4. Arnab Bhadra

    136 Points

  5. LeenSharma

    118 Points


22,770 questions
29,090 answers
65,119 comments
27,635 users