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

I forgot my password
All Activity
Questions
Unanswered
Tags
Subjects
Users
Ask
Lists
Previous
Blogs
New Blog
Exams
First time here? Checkout the
FAQ
!
x
×
Close
Use the google search bar on side panel. It searches through all previous GATE/other questions. For hardcopy of previous year questions please see
here
Recent questions tagged grammar
0
votes
0
answers
1
Formal Languages
Let r1 = (b*ab*ab*ab*)* and r2= (b*ab*ab*)*. What is L(r1) ∩ L(r2)? a) L[b*ab*ab*ab*)*] b) L[b*ab*ab*)*] c) L[b*ab*ab*)6] d) L[b*ab*ab*ab*ab*ab*ab*)*]
asked
4 days
ago
in
Theory of Computation
by
Sambhrant Maurya
Junior
(
757
points)

22
views
theoryofcomputation
grammar
regularlanguages
0
votes
0
answers
2
Formal Languages
Let r1= (a+b2)* , r2 = (a* + b*)* , r3 = (a2 + b)* Which of the following is true? a)L(r1) is a subset of L(r2) and L(r3) is a subset of L(r2) b)L(r2) is a subset of L(r1) and L(r2) is a subset of L(r3) c)L(r1) = L(r3) is a subset of L(r2) d) L(r1) U L(r3) = L(r2)
asked
4 days
ago
in
Theory of Computation
by
Sambhrant Maurya
Junior
(
757
points)

18
views
theoryofcomputation
grammar
regularlanguages
0
votes
1
answer
3
Formal Languages
If G= ({S} , {a}, {S>SS} , S), then language L(G) is a)ϕ b)aa(a)* c)(aa)* d)None of these
asked
4 days
ago
in
Theory of Computation
by
Sambhrant Maurya
Junior
(
757
points)

19
views
theoryofcomputation
finiteautomata
grammar
+1
vote
0
answers
4
LL(1) Parsing
To compute FOLLOW(A) for any grammar symbol A a) We must compute FIRST of some grammar symbols. b) No need of computing FIRST of some symbols. c) Maybe compute FIRST of some symbols. d) None of the above. The answer is given as option (A) but if we take ... know that $ will definitely in FOLLOW(S) and we didn't computed FIRST of any symbol for it. So option (C) should be the answer.
asked
Oct 10
in
Compiler Design
by
garvit_vijai
(
51
points)

12
views
compilerdesign
ll1
grammar
parsing
0
votes
1
answer
5
L attributed grammer
I know that every S attributed grammar is L attributed but not vice versa. Can anybody give example of the case if i print the semantic rules using L attributed the result will be different from the S attributed evaluation ? And how should i print the rules in both cases. Explain both case in this example :
asked
Oct 8
in
Compiler Design
by
Na462
Loyal
(
6.4k
points)

13
views
compilerdesign
syntaxdirectedtranslation
grammar
0
votes
0
answers
6
self doubt
Every regular set has an LR(1) grammar. What does this line mean??
asked
Sep 20
in
Compiler Design
by
Vegeta
(
369
points)

20
views
compilerdesign
parser
grammar
+1
vote
1
answer
7
Handle in a grammar
Consider the following Grammar : S > ZZ Z > xZy Which of following represent a handle in the generation of the string "xxxyxy" ? A. ZxZ B. Zxy C. xZxy D. xZ Please explain little about handles too i have little doubt in it. And do explain difference between viable prefix and Handle Please :)
asked
Sep 18
in
Compiler Design
by
Na462
Loyal
(
6.4k
points)

40
views
compiler
grammar
viableprefix
0
votes
0
answers
8
Doubt in Grammar
What is the difference between phase structured grammar and phrase structured grammar?
asked
Sep 16
in
Theory of Computation
by
goluabhinan
(
101
points)

11
views
theoryofcomputation
grammar
contextsensitive
compilerdesign
0
votes
0
answers
9
Doubt
What is the meaning of epsilon free LL(1) grammar? Give an example of epsilon free LL(1) grammar and a LL(1) grammar with epsilon.
asked
Sep 16
in
Compiler Design
by
soumayan bandhu
Junior
(
743
points)

7
views
ll1
compilerdesign
grammar
0
votes
1
answer
10
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
in
Theory of Computation
by
goluabhinan
(
101
points)

27
views
theoryofcomputation
grammar
ambiguous
0
votes
0
answers
11
Doubt in Grammar
Below is the grammar then find the language generated by given grammar S → ABC AB → aAx bAy  ε xb → bx ya → ay C → ε yb → by xC → BaC aB → Ba yC → BbC bB → Bb xa → ax Correct option : (a) L = {ww ∈ (a, b)∗, and xa(w) = xb(w)} (b) L = {ww ⊆ (a, b)+, and w is a palandrom string (c) L = {ww ⊆ (a, b)∗, and w = xx, where X = (a, b)∗} (d) None of the above
asked
Sep 10
in
Theory of Computation
by
goluabhinan
(
101
points)

23
views
theoryofcomputation
grammar
contextsensitive
0
votes
1
answer
12
Ambiguity of Grammer
asked
Sep 2
in
Theory of Computation
by
Na462
Loyal
(
6.4k
points)

26
views
theoryofcomputation
grammar
compilerdesign
+1
vote
0
answers
13
Doubt
Does this grammar generates string of atleast length 2 S>AA A>aA  bA  a  b
asked
Sep 1
in
Theory of Computation
by
aditi19
Junior
(
863
points)

39
views
grammar
0
votes
1
answer
14
Doubt
L(G)={$a^mb^n$m>n>=1} is the language context free?
asked
Aug 26
in
Theory of Computation
by
aditi19
Junior
(
863
points)

63
views
grammar
0
votes
1
answer
15
Grammars
Please provide example to disapprove the following points: 1.every DCFG need not be a LR(K). 2.every DCFG need not be a LL(K). 3.every DCFL is not LL(k).
asked
Jul 22
in
Compiler Design
by
junaid ahmad
Loyal
(
9k
points)

52
views
compilerdesign
grammar
0
votes
1
answer
16
UGCNETJuly2018II36
Consider the following two Grammars: $G_1 \: : \: S \rightarrow SbS \mid a$ $G_2 : S \rightarrow aB \mid ab, \: A \rightarrow GAB \mid a, \: B \rightarrow ABb \mid b$ Which one of the folloeing options is correct? Only $G_1$ is ambiguous Only $G_2$ is ambiguous Both $G_1$ and $G_2$ are ambiguous Both $G_1$ and $G_2$ are not ambiguous
asked
Jul 13
in
Theory of Computation
by
Pooja Khatri
Active
(
4.3k
points)

28
views
ugcnetjuly2018ii
theoryofcomputation
grammar
0
votes
2
answers
17
UGCNETJuly2018II38
The set $A = \{ 0^n \: 1^n \: 2^n \mid n=1, 2, 3, \dots \}$ is an example of a grammar that is Context sensitive Context free Regular None of the above
asked
Jul 13
in
Theory of Computation
by
Pooja Khatri
Active
(
4.3k
points)

46
views
ugcnetjuly2018ii
theoryofcomputation
grammar
+1
vote
2
answers
18
Languages
Consider a language over Σ={a,b} the description of L is given below. L={ PQ  P ∈(a,b)* , Q ∈ (a,b)* and na(P) = nb(Q) }. Select the correct option. 1. L is DCFL but not regular. 2. L is CSL but not CFL. 3. L is CFL but not DCFL. 4. None of these.
asked
Jul 3
in
Theory of Computation
by
Priyansh Singh
(
155
points)

104
views
theoryofcomputation
regularlanguages
contextfreelanguage
grammar
+2
votes
1
answer
19
Introduction to Formal Language, Fall 2017
asked
Jun 30
in
Theory of Computation
by
Apoorva Jain
(
157
points)

73
views
theoryofcomputation
regularlanguages
peterlinz
finiteautomata
grammar
0
votes
1
answer
20
Grammer
A grammar will be meaningless of the (a) terminal set and nonterminal set are not disjoint (b) left hand side of a productions is a single terminal (c) left hand side of a production has no nonterminal (d) all of the above
asked
Jun 25
in
Theory of Computation
by
K ANKITH KUMAR
(
173
points)

65
views
theoryofcomputation
grammar
0
votes
0
answers
21
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
in
Compiler Design
by
Nikhil Patil
(
497
points)

125
views
compilerdesign
grammar
ambiguous
+1
vote
2
answers
22
Gradup topicwise question doubt
Identify the language generated by the following grammar: $S>AB$ $A>aAb\epsilon$ $B>bBb$ (A)$\{a^m b^nn≥m, m>0\}$ (B)$\{a^m b^nn≥m, m≥0\}$ (C)$\{a^m b^nn>m, m>0\}$ (D)$\{a^m b^nn>m, m≥0\}$ I select option C but it is wrong, correct answer is option D. I could not understand Gradup answer explanation.Please help me to rectify my fault.
asked
May 24
in
Theory of Computation
by
Sona Barman
Active
(
1.2k
points)

82
views
theoryofcomputation
language
of
grammar
0
votes
4
answers
23
Context Free Language
L= { $a^{n}b^{m}$  $n<=m<=2n$ } a) DCFL b) CFL but not DCFL c) Not CFL
asked
May 6
in
Theory of Computation
by
Subham Nagar
Junior
(
679
points)

155
views
contextfreelanguage
theoryofcomputation
grammar
0
votes
1
answer
24
Attribute Grammar
Can someone explain these terms clearly these terms with examples? Attribute Grammar Synthesized attributes Inherited attributes L and S Attributes
asked
Apr 5
in
Compiler Design
by
smsubham
Loyal
(
7.9k
points)

53
views
compilerdesign
grammar
0
votes
1
answer
25
LL(n)
LL(1) parser cannot accept nondeterministic grammar at we have only single lookahead and there can be no predictable parsing in this case. Suppose we have LL(n) and we are given that maximum length of nondeterminism in a production is n  1. Can we use this grammar for LL(n) predictive parsing?
asked
Apr 4
in
Compiler Design
by
smsubham
Loyal
(
7.9k
points)

127
views
compilerdesign
ll1
parsing
lrparser
grammar
0
votes
3
answers
26
LR(0) Parsing Table
Please anyone create a $LR(0)$ Parsing table on this grammar and show the working of each step: $S' \rightarrow S$ $S \rightarrow S$;$A \mid A$ $A \rightarrow E \mid id := E$ $E \rightarrow E+id \mid id$ NonTerminals: $S'$ $S$ $A$ $E$ Terminals$: ; := + id$ Please take a screenshot of copy and show in the answer the whole working.
asked
Mar 18
in
Compiler Design
by
rahuldb
Junior
(
667
points)

208
views
compilerdesign
lrparser
parsing
grammar
+1
vote
3
answers
27
Find the grammar for the languages (PeterLinz)
asked
Feb 27
in
Theory of Computation
by
Mk Utkarsh
Boss
(
20.1k
points)

136
views
theoryofcomputation
peterlinz
grammar
+1
vote
1
answer
28
Exercise 1.2
Find the grammar for the following language $L = \left \{ w: \left  w \right  mod 3 \geq \left  w \right  mod 2 \right \}$
asked
Feb 26
in
Theory of Computation
by
Mk Utkarsh
Boss
(
20.1k
points)

98
views
theoryofcomputation
grammar
peterlinz
+2
votes
1
answer
29
PeterLinz (Exercise 1.2)
$L = \left \{ a^{n} b^{m} : n\geq 0,m>n \right \}$ Find a grammar that generates L3
asked
Feb 26
in
Theory of Computation
by
Mk Utkarsh
Boss
(
20.1k
points)

130
views
theoryofcomputation
peterlinz
grammar
+1
vote
1
answer
30
Derivation Trees, Peter Linz
Which of the following is false for derivation tree of CFG $G (V, T, P, S)$ ? The root is labeled $S$. Every leaf has a label from $V ⋃ T ⋃ \{ λ \}$. A vertex with a child labeled $λ$ can only have it as the rightmost child. $\text{1 & 3}$ $\text{1 & 2}$ $\text{2 & 3}$ $\text{Only 2}$
asked
Feb 24
in
Theory of Computation
by
tarun_svbk
Active
(
1.6k
points)

64
views
theoryofcomputation
peterlinz
grammar
derivationtree
Page:
1
2
3
4
5
6
...
9
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
List of Available Exams
New Assignment on Network programming : P2P simulation
Theory of Computation  GO Classroom
Probability  GO Classroom
Daily Quiz
Follow @csegate
Gatecse
Recent questions tagged grammar
Recent Blog Comments
Nice 2 know. You are welcome. :)
Hello @Arjun, I got books now...thanks for your...
You may contact FedEx local delivery office. It...
Yes you are right, it's showing this status from...
FedEx delivery is shown and as per that it is out...
40,927
questions
47,580
answers
146,423
comments
62,311
users