The Gateway to Computer Science Excellence
First time here? Checkout the FAQ!
x
0 votes
97 views

UGCNET-DEC2018-II-40.8

  1. UGCNET-DEC2018-II-200
  2. UGCNET-DEC2018-II-200
  3. UGCNET-DEC2018-II-200
  4. UGCNET-DEC2018-II-200

The grammar $S \rightarrow (S) \mid SS \mid \epsilon$ is not suitable for predictive parsing because the grammar is

  1. Right recursive
  2. Left recursive
  3. Ambiguous
  4. An operator grammar
asked in Others by Veteran (414k points)
edited by | 97 views
+1
A grammar which have left recursive and right recursive on a specific Non-Terminal is Ambiguous grammar.

So, option C is preferrable.

1 Answer

0 votes
This grammar is Left as well as Right recursive, it is Ambiguous Grammar for sure.
Also, if you will try for some strings, you will be getting more than 1 ways for that, hence Ambiguous
answered by Junior (865 points)

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
49,814 questions
54,518 answers
188,351 comments
75,294 users