The Gateway to Computer Science Excellence
For all GATE CSE Questions
Toggle navigation
Facebook Login
or
Email or Username
Password
Remember
Login
Register

I forgot my password
Activity
Questions
Unanswered
Tags
Subjects
Users
Ask
Prev
Blogs
New Blog
Exams
Recent questions tagged ambiguous
0
votes
0
answers
1
Michael Sipser Edition 3 Exercise 2 Question 51 (Page No. 159)
Show that every DCFG is an unambiguous CFG.
asked
Oct 13
in
Theory of Computation
by
Lakshman Patel RJIT
Veteran
(
54.7k
points)

3
views
michaelsipser
theoryofcomputation
contextfreegrammars
ambiguous
proof
0
votes
0
answers
2
Michael Sipser Edition 3 Exercise 2 Question 46 (Page No. 158)
Consider the following CFG $G:$ $S \rightarrow SS \mid T$ $T \rightarrow aT b \mid ab$ Describe $L(G)$ and show that $G$ is ambiguous. Give an unambiguous grammar $H$ where $L(H) = L(G)$ and sketch a proof that $H$ is unambiguous.
asked
Oct 12
in
Theory of Computation
by
Lakshman Patel RJIT
Veteran
(
54.7k
points)

6
views
michaelsipser
theoryofcomputation
contextfreegrammars
ambiguous
proof
0
votes
0
answers
3
Ullman (Compiler Design) Edition 2 Exercise 4.8 Question 1 (Page No. 285  286)
The following is an ambiguous grammar for expressions with $n$ binary, infix operators, at $n$ ... ambiguous and unambiguous) grammars compare? What does that comparison tell you about the use of ambiguous expression grammars?
asked
Aug 20
in
Compiler Design
by
Lakshman Patel RJIT
Veteran
(
54.7k
points)

10
views
ullman
compilerdesign
grammar
ambiguous
parsing
des
0
votes
0
answers
4
Ullman (Compiler Design) Edition 2 Exercise 4.3 Question 3 (Page No. 217)
The following grammar is proposed to remove the "danglingelse ambiguity" discussed in Section $4.3.2$: $stmt\rightarrow if\: expr\: then\: stmt\mid matchedstmt$ $matchedstmt \rightarrow if \:expr \:then \:matchedstmt\: else\: stmt\mid other$ Show that this grammar is still ambiguous.
asked
Aug 20
in
Compiler Design
by
Lakshman Patel RJIT
Veteran
(
54.7k
points)

8
views
ullman
compilerdesign
grammar
ambiguous
descriptive
+1
vote
0
answers
5
Ullman (Compiler Design) Edition 2 Exercise 4.2 Question 2 (Page No. 206  207)
Repeat Question $4.2.1$ for each of the following grammars and strings: $S\rightarrow 0S1\mid 01$ with string $000111$. $S\rightarrow +SS\mid \ast SS\mid a$ with string $+\ast aaa$ ... $bfactor\:\rightarrow\:not\:bfactor\mid (bexpr)\mid true\mid false$
asked
Aug 17
in
Compiler Design
by
Lakshman Patel RJIT
Veteran
(
54.7k
points)

11
views
ullman
compilerdesign
contextfreegrammars
parsetree
ambiguous
descriptive
0
votes
1
answer
6
Ullman (Compiler Design) Edition 2 Exercise 4.2 Question 1 (Page No. 206)
Consider the contextfree grammar:$S\rightarrow SS + \mid SS {\ast} \mid a$and the string $aa + a{\ast}$. Give a leftmost derivation for the string. Give a rightmost derivation for the string. ... for the string. Is the grammar ambiguous or unambiguous? Justify your answer. Describe the language generated by this grammar.
asked
Aug 7
in
Compiler Design
by
Lakshman Patel RJIT
Veteran
(
54.7k
points)

42
views
ullman
compilerdesign
contextfreegrammars
parsetree
ambiguous
descriptive
+1
vote
2
answers
7
Ullman (Compiler Design) Edition 2 Exercise 2.2 Question 3 (Page No. 51)
Which of the grammars are ambiguous? $S\rightarrow 0S1 \mid 01$ $S\rightarrow +SS \mid SS \mid a$ $S\rightarrow S(S)S \mid \epsilon$ $S\rightarrow aSbS \mid bSaS \mid \epsilon$ $S\rightarrow a \mid S+S \mid SS \mid S^{\ast} \mid (S)$
asked
Jul 26
in
Compiler Design
by
Lakshman Patel RJIT
Veteran
(
54.7k
points)

22
views
ullman
compilerdesign
contextfreegrammars
ambiguous
+1
vote
0
answers
8
Self Doubt : Ambiguity
Why is ambiguity in regular language is decidable and not decidable in CFL ? Can you give Example?
asked
May 10
in
Theory of Computation
by
logan1x
Junior
(
879
points)

121
views
theoryofcomputation
finiteautomata
ambiguous
regularlanguages
contextfreelanguage
context
0
votes
1
answer
9
Michael Sipser Edition 3 Exercise 2 Question 9 (Page No. 155)
Give a contextfree grammar that generates the language $A=\{a^{i}b^{j}c^{k}\mid i=j$ $\text{or}$ $ j=k$ $\text{where}$ $ i,j,k\geq 0\}.$ Is your grammar ambiguous$?$ Why or why not$?$
asked
May 1
in
Theory of Computation
by
Lakshman Patel RJIT
Veteran
(
54.7k
points)

17
views
michaelsipser
theoryofcomputation
contextfreelanguages
ambiguous
grammars
0
votes
0
answers
10
Peter Linz Edition 4 Exercise 5.2 Question 19 (Page No. 145)
Prove the following result. Let $G = (V, T, S, P )$ be a contextfree grammar in which every $A ∈ V$ occurs on the left side of at most one production. Then $G$ is unambiguous.
asked
Apr 14
in
Theory of Computation
by
Naveen Kumar 3
Boss
(
15.2k
points)

15
views
peterlinz
theoryofcomputation
contextfreegrammars
ambiguous
0
votes
0
answers
11
Peter Linz Edition 4 Exercise 5.2 Question 18 (Page No. 145)
Is the string $aabbababb$ in the language generated by the grammar $S → aSSb$? Show that the grammar with productions $S\rightarrow aAb\lambda,$ $A\rightarrow aAb\lambda$ is unambiguous.
asked
Apr 14
in
Theory of Computation
by
Naveen Kumar 3
Boss
(
15.2k
points)

20
views
peterlinz
theoryofcomputation
contextfreegrammars
ambiguous
0
votes
0
answers
12
Peter Linz Edition 4 Exercise 5.2 Question 16 (Page No. 145)
Show that the grammar with productions $S\rightarrow aAB,$ $A\rightarrow bBb,$ $B\rightarrow A\lambda.$ is unambiguous.
asked
Apr 14
in
Theory of Computation
by
Naveen Kumar 3
Boss
(
15.2k
points)

23
views
peterlinz
theoryofcomputation
grammar
ambiguous
0
votes
0
answers
13
Peter Linz Edition 4 Exercise 5.2 Question 15 (Page No. 145)
Show that the grammar with productions $S\rightarrow SS,$ $S\rightarrow \lambda,$ $S\rightarrow aSb,$ $S\rightarrow bSa.$ is ambiguous.
asked
Apr 14
in
Theory of Computation
by
Naveen Kumar 3
Boss
(
15.2k
points)

33
views
peterlinz
theoryofcomputation
grammar
ambiguous
0
votes
0
answers
14
Peter Linz Edition 4 Exercise 5.2 Question 14 (Page No. 145)
Show that the grammar $S\rightarrow aSbSS\lambda$ is ambiguous, but that the language denoted by it is not.
asked
Apr 14
in
Theory of Computation
by
Naveen Kumar 3
Boss
(
15.2k
points)

16
views
peterlinz
theoryofcomputation
grammar
ambiguous
0
votes
0
answers
15
Peter Linz Edition 4 Exercise 5.2 Question 13 (Page No. 145)
Show that the following grammar is ambiguous. $S\rightarrow aSbSbSaS\lambda$
asked
Apr 14
in
Theory of Computation
by
Naveen Kumar 3
Boss
(
15.2k
points)

16
views
peterlinz
theoryofcomputation
grammar
ambiguous
0
votes
0
answers
16
Peter Linz Edition 4 Exercise 5.2 Question 11 (Page No. 145)
Is it possible for a regular grammar to be ambiguous?
asked
Apr 14
in
Theory of Computation
by
Naveen Kumar 3
Boss
(
15.2k
points)

13
views
peterlinz
theoryofcomputation
regulargrammar
ambiguous
0
votes
0
answers
17
Peter Linz Edition 4 Exercise 5.2 Question 7 (Page No. 145)
Construct an unambiguous grammar equivalent to the grammar in Exercise 6.
asked
Apr 14
in
Theory of Computation
by
Naveen Kumar 3
Boss
(
15.2k
points)

18
views
peterlinz
theoryofcomputation
grammar
ambiguous
0
votes
0
answers
18
Peter Linz Edition 4 Exercise 5.2 Question 6 (Page No. 145)
Show that the following grammar is ambiguous. $S\rightarrow ABaaB,$ $A\rightarrow aAa,$ $B\rightarrow b.$
asked
Apr 14
in
Theory of Computation
by
Naveen Kumar 3
Boss
(
15.2k
points)

14
views
peterlinz
theoryofcomputation
grammar
ambiguous
0
votes
0
answers
19
Peter Linz Edition 4 Exercise 5.2 Question 4 (Page No. 145)
Show that every sgrammar is unambiguous.
asked
Apr 14
in
Theory of Computation
by
Naveen Kumar 3
Boss
(
15.2k
points)

8
views
peterlinz
theoryofcomputation
ambiguous
grammar
0
votes
0
answers
20
DFA NFA and ambiguity
Why is Regular grammar obtained from DFA always unambiguous? Why Regular grammar obtained from NFA may or may not be ambiguous?
asked
Dec 7, 2018
in
Theory of Computation
by
OneZero
Active
(
2.1k
points)

53
views
theoryofcomputation
nfa
ambiguous
0
votes
1
answer
21
Doubt in Grammar
Consider the following grammar which of the following is/are ambiguous? (i) S → y  SxS (ii) S → E  ExS and E → y (iii) S → Sxy  y
asked
Sep 11, 2018
in
Theory of Computation
by
goluabhinan
(
71
points)

54
views
theoryofcomputation
grammar
ambiguous
0
votes
0
answers
22
UGC NET DEC 2017 PAPER 2 Q 34
Which of the following statements is/are TRUE ? (i) The grammar S → SS  a is ambiguous (where S is the start symbol). (ii) The grammar S → 0S1  01S  e is ambiguous (the special symbol e represents the empty string and S is the start symbol). (iii) The grammar ... TRUE (D) All of (i), (ii) and (iii) are TRUE Sure shot (i) and (ii) are true i want third one in brief
asked
Jun 19, 2018
in
Compiler Design
by
Nikhil Patil
Junior
(
505
points)

279
views
compilerdesign
grammar
ambiguous
0
votes
0
answers
23
Compiler design
Hi mates, Show that it is ambiguous grammar TIA S>aAB/bBA A>bS/a B>aS/b
asked
Nov 24, 2017
in
Compiler Design
by
Sahil1994
Junior
(
927
points)

74
views
compilerdesign
ambiguous
+1
vote
1
answer
24
UGCNETNov2017ii34
Which of the following statements is/are TRUE ? (a) The grammar $S \rightarrow SS\ \ a$ is ambiguous. (Where $S$ is the start symbol) (b) The grammar $S \rightarrow 0S1\ \ 01S\ \ \epsilon$ is ambiguous. (The special symbol $\epsilon$ represents the empty string) (Where $S$ is the ... and (c) are TRUE. $(3)$ Only (b) and (c) are TRUE. $(4)$ All of (a), (b) and (c) are TRUE.
asked
Nov 5, 2017
in
Theory of Computation
by
Arjun
Veteran
(
424k
points)

1.1k
views
ugcnetnov2017ii
grammar
contextfreelanguage
ambiguous
0
votes
0
answers
25
Ambiguity
Ques. S > Aa/bAc/dc A > d Isn't this grammar Ambiguous? If First(S) has more than one production giving the same first value, isn't it ambiguous?
asked
Aug 22, 2017
in
Compiler Design
by
Warlock lord
Active
(
3.3k
points)

84
views
ambiguous
grammar
+2
votes
1
answer
26
REGULAR OR NOT
As given that 1st is not regular and 2nd is regular as 1st not form AP but 2nd form.but if in 2nd we fix value of m and n same then it will work as 1st(not regular) so 2nd also should not be regular.as i know if we fix m or n value as any constant it will be AP but what if same???
asked
Aug 8, 2017
in
Theory of Computation
by
learner_geek
Active
(
3.2k
points)

246
views
theoryofcomputation
settheory&algebra
compilerdesign
ambiguous
regularlanguages
+2
votes
1
answer
27
REGULAR OR NOT
Please mention reason with answer:
asked
Aug 8, 2017
in
Theory of Computation
by
learner_geek
Active
(
3.2k
points)

90
views
theoryofcomputation
compilerdesign
ambiguous
regularlanguages
settheory&algebra
0
votes
1
answer
28
TestBook TestSeries
Consider the following statements : i) An ambiguous grammar can not generate DCFL. ii) An unambiguous grammar will always generate deterministic context free language. iii) Any nonempty language admits an ambiguous grammar. iv) All regular grammars are unambiguous. Which of the above is/are TRUE? i) and iv) only ii) and iii) only iii) only ii) and iv) only
asked
Jan 29, 2017
in
Theory of Computation
by
vnc
Active
(
2.8k
points)

89
views
theoryofcomputation
ambiguous
0
votes
0
answers
29
Self Doubt
By seeing a grammar I can say it is ambiguous or not. But How can I say it is inherently ambiguous or not.?
asked
Jan 22, 2017
in
Theory of Computation
by
Lucky sunda
Active
(
4.5k
points)

133
views
theoryofcomputation
inherentlyambiguous
ambiguous
0
votes
0
answers
30
Grammar ambiguity and parsing
$\begin{align*} \text {stmt} &\rightarrow \text{if expr then stmt else stmt} \\ & \;\; \;\;  \text{ if expr then stmt} \\ & \;\; \;\;  \text{ other} \end{align*}$ Which of the following statement/s is ... and the ambiguity cannot be resolved. B. The grammar is unambiguous C. The grammar is ambiguous and the ambiguity can be resolved D. None of these
asked
Dec 15, 2016
in
Compiler Design
by
dd
Veteran
(
57k
points)

246
views
compilerdesign
ambiguous
danglingelseproblem
parsing
Page:
1
2
next »
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
Recent Posts
Linear Algebra Important Points
GATE 2020
OFFICIAL GATE MOCK TEST RELEASED
IIITH: Winter Research Admissions 2019 (For Spring 2020)
TIFR and JEST exam
Follow @csegate
Recent questions tagged ambiguous
Recent Blog Comments
i also don't have any pdf, actually, I added the...
i don't have , if you have upload it
@mohan123 Do you have all standard book...
bro can be upload all standard book questions in...
it'll take 34 days but for most purpose you can...
50,648
questions
56,441
answers
195,294
comments
100,084
users