What is a Context-Sensitive Grammar/Language? + Example

แชร์
ฝัง
  • เผยแพร่เมื่อ 26 ก.ย. 2024
  • Here we define a context-sensitive grammar and language, as well as give an example of a language that is context-sensitive but not context-free: {a^n b^n c^n : n at least 0}. The idea is that a CSG can do exactly what a CFG can do, except that it enforces a "context" in which the rule can be applied.
    If you like this content, please consider subscribing to my channel: / @easytheory
    ▶SEND ME THEORY QUESTIONS◀
    ryan.e.dougherty@icloud.com
    ▶ABOUT ME◀
    I am a professor of Computer Science, and am passionate about CS theory. I have taught many courses at several different universities, including several sections of undergraduate and graduate theory-level classes.

ความคิดเห็น • 15

  • @truefaceofevil
    @truefaceofevil 3 ปีที่แล้ว +4

    I’ve been attempting to understand CFGs and CSGs a bit better for a while now, and within the first few minutes of your explanation, a lightbulb went on. Thank you!

  • @cameronball3998
    @cameronball3998 2 ปีที่แล้ว +1

    This was very helpful! Thank you. My professor and textbook provide almost no examples, so this was very demonstrative.

  • @jayk253
    @jayk253 2 ปีที่แล้ว +3

    Nice and clear explanation! Thank you a lot

  • @powzewu7854
    @powzewu7854 3 หลายเดือนก่อน

    Thanks for the explanation

  • @boriscrisp518
    @boriscrisp518 5 วันที่ผ่านมา

    worlds most complex example expressed verbally for extra difficulty

  • @assaydriveby6404
    @assaydriveby6404 2 ปีที่แล้ว +2

    Awesome video my teacher should really watch this his being fucking up my course

  • @con7
    @con7 ปีที่แล้ว

    Thank you, better explanation than my prof's by a long shot

  • @JohnnyIsTsunami
    @JohnnyIsTsunami 2 ปีที่แล้ว

    Thank you!! This helped a lot with my paper

  • @Cowboy8625
    @Cowboy8625 2 ปีที่แล้ว +11

    im more confused.

    • @اشکانمحمدی-ز1ث
      @اشکانمحمدی-ز1ث 2 ปีที่แล้ว +2

      That's probably because of the algebraic symbols that soon entered the play

  • @jwc7285
    @jwc7285 ปีที่แล้ว

    explain so well!

  • @fatmazahra8191
    @fatmazahra8191 2 ปีที่แล้ว

    thank you for helping
    🙏

  • @trendystatusforyou
    @trendystatusforyou 5 หลายเดือนก่อน

    Great

  • @SniperSmiley
    @SniperSmiley 2 ปีที่แล้ว +1

    This got me thinking about quaternions i^2 j^2 k^2-> iijjkk-> i(ij)(jk)k->ikik->(ik)^2->(-j)^2->1 so this is context sensitive