The first production for a^n.b^n.c^n was S -> aSBc / E But doesn't this mean the same thing as S -> E S -> aSBc But didn't sir told that S can not appear on right once it has been given a null production?
The only exception in type-1 grammar was that if S-->∈ is present then no other production like "cB-->aSc" should have S on the RHS. So basically null production was needed to make an exit from sentential form. So "S--> " vali productions mein hi RHS mein 'S' can come tabhi toh exit kar payege na sentential form mein se. I hope you understood. Thanks for raising this doubt. It helped me analyze type 1 grammar more clearly. B/c in exam if such que would have come than my first thought would definitely be that "type grammar can't have S on the RHS in any other production rule if S-->∈ production is present". Even though sir has taught this through I would have made this mistake. B/c at first your doubt seemed to be correct.
Can someone explain why the context sensitive grammar for generating a^n.b^n.c^n can't be simply written as- S -> aAbBcC / E / abc aAbBcC -> aaAbbBccC A -> a B -> b C -> c It satisfies both the criterion needed to be type 1. Every production has atleast 1 non-terminal in LHS, and |LHS|
Can this grammar generate string: a^5b^5c^5 ? Can your grammar generate for all n>=0 strings? No it can't. What you have written can only generate strings {∈, abc, aabbcc, aaabbbccc}. So no this is absolutely incorrect grammar. What sir has written is correct. And second thing, we want a grammar that can generate infinite number of strings. So such grammar must have loop in it to make that happen. And your grammar does not have any loops.
19:50 sir i have written grammar before you in just 8 production what's wrong here ????? S---->aSBCd/NULL CdB---->BCd dC----->Cd aB---->ab bB----->bb bC----->bc cC----->cc and sir in your solution production 3 and 5 are same so it is grammar of 9 production.
You have make most difficult concept of TOC easy as cake .
Thank you so much Sir 💕
Sir please C& DS ka video banaiye jab poset khatam ho jaye kyu ki C& DS Weightage Jayda h baki subject
production 3 and 5 are same 22:12
@20:00, productions 3 & 5 are same so one of them can be removed.
insane work ethics guruji
So Easily Explainedd 😍
@19:50
For a^nb^nc^nd^n
S->aSAd l epsilon
dA-> Ad
A-> Bc
cB->Bc
aB-> ab
bB->bb
Is this grammer correct?
at 19:52 I have obtained the grammar by 8 production rule. Is this correct?
S -> aSBCd/ null
dBC -> BCd
CB -> BC
aB -> ab
bB -> bb
bC -> bc
cC -> cc
Yes I also made same grammar
so is this one correct?
A CSG is a CFG without null productions, so please can u explain me why did you use S->epsilon
The first production for a^n.b^n.c^n was S -> aSBc / E
But doesn't this mean the same thing as
S -> E
S -> aSBc
But didn't sir told that S can not appear on right once it has been given a null production?
The only exception in type-1 grammar was that if S-->∈ is present then no other production like "cB-->aSc" should have S on the RHS. So basically null production was needed to make an exit from sentential form. So "S--> " vali productions mein hi RHS mein 'S' can come tabhi toh exit kar payege na sentential form mein se.
I hope you understood.
Thanks for raising this doubt. It helped me analyze type 1 grammar more clearly. B/c in exam if such que would have come than my first thought would definitely be that "type grammar can't have S on the RHS in any other production rule if S-->∈ production is present". Even though sir has taught this through I would have made this mistake. B/c at first your doubt seemed to be correct.
@@harshilshah8983 so you mean to say that only those productions which have just S on lhs can have S somewhere in rhs?
@@_strangelet__ Yes. B/c null can only be accessed via S. And S production contains loop and to get out of loop we need null.
Can someone explain why the context sensitive grammar for generating a^n.b^n.c^n can't be simply written as-
S -> aAbBcC / E / abc
aAbBcC -> aaAbbBccC
A -> a
B -> b
C -> c
It satisfies both the criterion needed to be type 1. Every production has atleast 1 non-terminal in LHS, and |LHS|
Can this grammar generate string: a^5b^5c^5 ? Can your grammar generate for all n>=0 strings? No it can't. What you have written can only generate strings {∈, abc, aabbcc, aaabbbccc}. So no this is absolutely incorrect grammar. What sir has written is correct.
And second thing, we want a grammar that can generate infinite number of strings. So such grammar must have loop in it to make that happen. And your grammar does not have any loops.
@@harshilshah8983 oh yes you're right! My bad
Sir is it possible to provide lecture of each and every subject by October 2022 from ur side ??🙏🙏
@30:00 mann I got goosebumps literally
Sir what is one sided context sensitive grammar? Please give example also.......
respect.
What will be the grammar for n >=1.
great👍👍😊
suggestion: sir it would be better if u keep the video related to the topic mentioned.
Sir is epsilon is allowed in csl
For CSL, Epsilon is allowed only in starting production rule.... Except that Epsilon is not used in any other production rules
19:50 sir i have written grammar before you in just 8 production what's wrong here ?????
S---->aSBCd/NULL
CdB---->BCd
dC----->Cd
aB---->ab
bB----->bb
bC----->bc
cC----->cc
and sir in your solution production 3 and 5 are same so it is grammar of 9 production.
In your production rule number 3 CdB-->BCd is not following context sensitive grammar's format.
No it's not correct
What is CSG Rule @@siddharthpatel_IITKgp
🙏🙏🙏🙏🙏
🙏🙏🙏🙏🙏🙏