Deterministic Finite Automata (Example 4)

แชร์
ฝัง
  • เผยแพร่เมื่อ 18 ธ.ค. 2024

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

  • @Laeyz
    @Laeyz 5 ปีที่แล้ว +390

    'whatever happens in dead state , stays in dead state.' sounds familiar.

    • @lightbinger
      @lightbinger 4 ปีที่แล้ว +8

      I was writing same and saw your comment.

    • @sarthakpatel107
      @sarthakpatel107 3 ปีที่แล้ว +12

      'Whatever happens in Green mile, stays in green mile.'

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

      @@sarthakpatel107 or area 52

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

      People who ghost others do be like that

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

      Vegas

  • @mohammad_a_razeq2526
    @mohammad_a_razeq2526 4 ปีที่แล้ว +34

    This channel is really beautiful and very useful , thank's for your effforts

  • @arpitadaspoddar4336
    @arpitadaspoddar4336 7 ปีที่แล้ว +62

    I think the language will be like dfa accepts the string 01 or a string starting with atleast one 1 followed by 0. other wise the string 010 has atleast one 1 followed by 0, but 010 is not accepted according to dfa.

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

      i think it accepts only 01 and 1 followed by 0.

    • @mahmoudtarek7854
      @mahmoudtarek7854 6 ปีที่แล้ว +1

      The 1 followed by 0 must be at the beginning of the string, so 010 is not accepted.

    • @themuchy1
      @themuchy1 5 ปีที่แล้ว +3

      "Accepts the string '01', the string '10' or a string that starts with '1' followed by any number of '1's and a single '0' at the end"

    • @AliAhmed-gg1tz
      @AliAhmed-gg1tz 5 ปีที่แล้ว +2

      yeh bharwa fail karady ga tumhen

    • @mahnoorahmed8723
      @mahnoorahmed8723 5 ปีที่แล้ว

      It accepts all the strings with "atleast digit 1 followed by 0" or "01" so it doesn't matter what comes before 01 or after 01, it will accept it! So 0'01', '01'0 and '01'1 is acceptable. Same goes for the first situation too. We have to identify ouselves whether the string is from first situation or from second.

  • @mohammadvasimbaig8680
    @mohammadvasimbaig8680 ปีที่แล้ว +10

    00:09 Determining what the given DFA recognizes
    01:33 Two types of strings are accepted
    03:00 The DFA recognizes the string 0 1 or a string with at least one binary digit 1 followed by a 0.
    04:35 Deterministic Finite Automata (DFA) accepts strings of at least 1 binary digit 1 followed by a 0.
    05:59 The DFA does not have a place to go for certain inputs
    07:16 Dead state is a state in a DFA that leads to non-accepted strings.
    08:29 Implementing a DFA
    09:53 Not having a terminating state in a DFA leads to a dead state
    Crafted by Merlin AI.

  • @curtispatrick8072
    @curtispatrick8072 5 ปีที่แล้ว +40

    Great aid, but I think this one has a couple of problems. 1. (D) should transition to self on {0,1} because you've matched on the '1 followed by 0'. 2. (C) on {0} should transition to another state, (F) because while '00' will never match the '01' rule, it *might* match the '1 followed by 0' rule. (F) would transition to itself (F) on '0', but transition to (B) on 1.
    Of course, I could be wrong. I'm here because I'm looking at ANTLR and it talked about DFA and NFA and I have found these tutorials really useful, easy to consume, and easy to remember.

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว +5

      Here, the string 1111....10 (at least one 1 followed by 0 is not assumed to be a sub string, it just is at least one 1 followed by one 0. )
      For instance, 1110 will be accepted . But 11101 or 11100 will be rejected. So, stage D has to transition to Stage X to ensure rejection of the above mentioned strings. If stage D transitions to D itself, then 11101 and 11100 will both be accepted .
      If the case was that at least one 1 followed by a 0 was a sub-string(for example 11100 or 11101) then D should have transitioned to itself on 0 and 1 .

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว +5

      The same goes for your second argument. The question is not about 01 or 111...10 being sub-strings .
      It either exactly has to be 01 or 111.....10 (n number of 1s followed by a 0, where n=1,2,3....).

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว +15

      Although, there's a problem of clarity in the statement. The fact that it has not to be a sub string could have been stated better.
      L = {Accepts the string 01 or a string of at least one 1 ended by exactly one 0.} This could have been a more clear representation of the DFA.

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

      @@vishalkumarjha3368your machine will accept 1010 and also 010. So I think the correct answer is L= "accepts the string 01 or a string of atleast one '1' ended with single occurring 0"

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

      @@vipuljha1818 Neither 1010 nor 010 are accepted due to going to the dead state

  • @StudyArtist-pl2bn
    @StudyArtist-pl2bn 3 หลายเดือนก่อน

    00:07 Determining the language recognized by a DFA
    01:28 Deterministic Finite Automata in action
    02:56 DFA recognizes 0 1 or a string with at least one 1 followed by 0
    04:31 Illustrating the acceptance of binary strings by a DFA
    05:53 DFA transition fails for certain input strings
    07:13 Introduction to Dead State in DFA
    08:24 Deterministic Finite Automata example 4
    09:51 Not terminating state = dead state

  • @nehatadam6904
    @nehatadam6904 4 ปีที่แล้ว +92

    The state transition diagram is not complete. DFA is a machine for which every state must contain transition for every input symbol and single transition per input symbol.

    • @AlexAkira-yd4nk
      @AlexAkira-yd4nk 4 ปีที่แล้ว +9

      Thank you for the remark. I thought the state should be UNDEFINED, but your comment corrected my misconception.

    • @ShishiraNataraj
      @ShishiraNataraj 3 ปีที่แล้ว +27

      it is corrected by adding a dead state in the second half of the video

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

      @@ShishiraNataraj well he shouldve added the dead state from the very beginning....since he already explained what a dead state is in the earlier videos......It would prevent unnecessary confusions and climaxes

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

      He knows. Don't worry. That's why you should look the whole video before commenting.

    • @NeerajKrGupta-ys2ey
      @NeerajKrGupta-ys2ey 2 ปีที่แล้ว +1

      @Neha Tadam firstly watch complete video then only come to a conclusion

  • @vishalkumarjha3368
    @vishalkumarjha3368 3 ปีที่แล้ว +17

    Here, the string 1111....10 (at least one 1 followed by 0 is not assumed to be a sub string, it just is at least one 1 followed by one 0. )
    For instance, 1110 will be accepted . But 11101 or 11100 will be rejected. So, stage D has to transition to Stage X to ensure rejection of the above mentioned strings. If stage D transitions to D itself, then 11101 and 11100 will both be accepted .
    If the case was that at least one 1 followed by a 0 was a sub-string(for example 11100 or 11101) then D should have transitioned to itself on 0 and 1 .
    The question is not about 01 or 111...10 being sub-strings .
    It either exactly has to be 01 or 111.....10 (n number of 1s followed by a 0, where n=1,2,3....).
    So, basically
    1110 accepted.
    11101 rejected.
    11100 rejected.
    01 accepted.
    010 rejected.
    010101 rejected .
    As we can see, the examples which have been rejected above have 1110 and 01 as sub strings , but since they are not the complete strings, they are rejected.
    That's the demand of the question.
    Although, there's a problem of clarity in the statement. The fact that it has not to be a sub string could have been stated better.
    L = {Accepts the string 01 or a string of at least one 1 ended by exactly one 0.} This could have been a more clear representation of the DFA.

  • @haoranchang262
    @haoranchang262 7 ปีที่แล้ว +7

    I would say D should not go to the dead state. Because when you are in state D, which means there IS at least one '1' followed by a 'zero'. So no matter what the rest of the string looks like, it should be accepted.

    • @fimboaloha8535
      @fimboaloha8535 7 ปีที่แล้ว

      I have the same question as you.

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว +12

      @@fimboaloha8535 Here, the string 1111....10 (at least one 1 followed by 0 is not assumed to be a sub string, it just is at least one 1 followed by one 0. )
      For instance, 1110 will be accepted . But 11101 or 11100 will be rejected. So, stage D has to transition to Stage X to ensure rejection of the above mentioned strings. If stage D transitions to D itself, then 11101 and 11100 will both be accepted .
      If the case was that at least one 1 followed by a 0 was a sub-string(for example 11100 or 11101) then D should have transitioned to itself on 0 and 1 .
      The question is not about 01 or 111...10 being sub-strings .
      It either exactly has to be 01 or 111.....10 (n number of 1s followed by a 0, where n=1,2,3....).
      So, basically
      1110 accepted.
      11101 rejected.
      11100 rejected.
      01 accepted.
      010 rejected.
      010101 rejected .
      As we can see, the examples which have been rejected above have 1110 and 01 as sub strings , but since they are not the complete strings, they are rejected.
      That's the demand of the question.

    • @01aniruddhaislam26
      @01aniruddhaislam26 ปีที่แล้ว

      @@vishalkumarjha3368 thanks for the explanation.

  • @soniaasghar1094
    @soniaasghar1094 6 ปีที่แล้ว +3

    FAbulous way of teaching

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

    A DFA must have a transition for all symbols for all states. That was not a DFA from the beginning, and adding states to the automaton changes it from the original, which was not a dfa

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

      well that's incorrect

    • @parasytea
      @parasytea 7 หลายเดือนก่อน

      @@omarmarnissi1458 why ?

    • @ritvikreddy3959
      @ritvikreddy3959 6 หลายเดือนก่อน +2

      What does dfa say ? It should have states and transitions with only single path for specific inputs. The diagram at the start of the video was a dfa but it wasn't complete because it didn't correctly explain what would happen if c gets the input 0 and if final states get the input 0,1. But at the end of the video he added dead states but the language wasn't clear due to which there was a lot of confusion in comment section.

  • @mayureshwadgaonkar2265
    @mayureshwadgaonkar2265 5 ปีที่แล้ว +3

    Why haven't we applied a self loop for c if it's gets input 0..like we did for b for input 1

  • @Ali_Alhajji
    @Ali_Alhajji 3 ปีที่แล้ว +11

    So what this DFA does is :
    1) Accepts 01
    2) Accepts all strings that start with a sequence of 1s followed by a single 0.

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

    Thank you so much sir..... You saved my life

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

    4:28 Sir, Can I also say that, This DFA accepts any string not having 2nd input as '0' ?

    • @BlizZarDaSh
      @BlizZarDaSh 5 ปีที่แล้ว +1

      '10' is accepted by this DFA and the second input is '0'. Watch it again.

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

    Sir at 8:36 why we are not using self loop here on D for 0 and 1 please answer

  • @rajeevdey_8894
    @rajeevdey_8894 3 ปีที่แล้ว +6

    What happen if '1111' string goes?🙄
    According to me it will not reach upto final state. Means it is not acceptable?

    • @srinivasr1948
      @srinivasr1948 8 หลายเดือนก่อน

      it will not accept bro

  • @星际小男孩
    @星际小男孩 6 ปีที่แล้ว +4

    It is so fun, thank you very much.

  • @jennconn8378
    @jennconn8378 3 ปีที่แล้ว +1

    My God. It helps me a lot thank ypu

  • @IndieDeveloperGuy
    @IndieDeveloperGuy 3 ปีที่แล้ว +8

    So what this DFA does is :
    1) Accepts 01
    2) Accepts all strings that starts with 1 and ends with 0

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

      Your second point is wrong. It is supposed to be "Accepts all strings that have at least one '1' and end with '0'".
      The reason for this is that if you get a '0' after you are in state B, you will go to the terminating state D. After that, the string must be finished otherwise you go to the dead state X, as shown in the completed DFA. Be careful with these DFAs, they are extremely tricky and very easy to get wrong.

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

      @@usamabinmuzaffar692 no, you're wrong, if it doesn't start with a 1 it goes on the other branch

  • @Vinod_Pandey14
    @Vinod_Pandey14 8 หลายเดือนก่อน

    4:31 I think we can also say that a string of 0, 1 of min length 2 which starts and ends with different digits.

  • @tradermann
    @tradermann 5 ปีที่แล้ว +3

    7:04 - 'this DFA is not wrong'
    Yes it is. All DFAs have have transition FOR EVERY SYMBOL in the alphabet, FROM EVERY STATE. So before you drew that dead state, your DFA was wrong.
    Otherwise, nice video. :)

    • @keshavtha
      @keshavtha 5 ปีที่แล้ว +1

      if there is no state given for an output we assume that it is going to a dead state ,so he is not wrong in saying that the DFA was not wrong.

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

    01 and string starts with 1 and ends with 0??

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

    I have a que sir.. 001,010 in examples are called DFA or not?

    • @jyosthna3769
      @jyosthna3769 5 ปีที่แล้ว

      They are DFA only..... but not accepted by machine ..bcz the string 001 is not there in our language L.

  • @hectorg362
    @hectorg362 5 ปีที่แล้ว +3

    I freaken love you and this channel for this content!

  • @christiana.collamar8924
    @christiana.collamar8924 6 ปีที่แล้ว +3

    I think the constructed DFA only accepts a subset of strings defined by the language, e.g. the string 010 is not accepted even though it should be since it's a string with at least one 1 followed by a 0. To make the DFA accept such strings, I think these transitions must be followed:
    δ(E, 1) = B
    δ(D, 1) = B
    δ(X, 1) = B

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

      I think he ment , starting with atleast one lol

  • @anuragporwal9039
    @anuragporwal9039 5 ปีที่แล้ว +1

    For DFA ,at C there should be a input '0',this is NFA

  • @oguzkaanbulut2374
    @oguzkaanbulut2374 3 ปีที่แล้ว

    L should be { 01 or strings has zero only at last index} since state d has not a behaviour for inputs 0,1 to loop itself

  • @vardhman2344
    @vardhman2344 3 ปีที่แล้ว +1

    you have made the start state an accepting state also but this also means that the dfa accepts epsilon as input. Am i right?can start state be an accepting state?

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

    sir, what if in state c we get another 0?

  • @ayushiagrawal3009
    @ayushiagrawal3009 3 ปีที่แล้ว

    This DFA is still in complete as path 0 from the state B is not mentioned for example if we have a string 1011 then we can go from A to B at 1 but from B at 0 where we will go, we will be going to the dead state from B at 0. Please do mention this🙏🙏🙏🙏

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว

      If we get 0 at B, we will move to D. It is clearly mentioned.

  • @sriman8083
    @sriman8083 5 ปีที่แล้ว +11

    Sir I think it is not a DFA because in this all states not covers all transitions

    • @shantipriya4661
      @shantipriya4661 5 ปีที่แล้ว

      A deterministic finite automata does not need a transition from every state for every symbol.it is DFA

    • @RahulSahu-fy6mr
      @RahulSahu-fy6mr 5 ปีที่แล้ว +3

      Watch the video till the end. You will get to know the answer.

  • @udbhavvikramsingh3449
    @udbhavvikramsingh3449 3 ปีที่แล้ว

    Why not D goes back to state B if input is 1 at D, doing this way also satisfies the LANGUAGE right?????
    Correct me if i am wrong.

  • @20mymysf
    @20mymysf 5 ปีที่แล้ว +9

    What a plot twist! The X-state is like the zombie of the states!!

  • @gunashiva2760
    @gunashiva2760 7 ปีที่แล้ว

    very good explanation nice sir ..

    • @yashnarang637
      @yashnarang637 4 ปีที่แล้ว

      can you please explain me what this dfa recognizes?

  • @toxicsoul8147
    @toxicsoul8147 5 ปีที่แล้ว

    Can we put (0,1) loop in both D and E states?...then the dead state is not needed..

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

    What if b state doesn't get input 0 is the string can be accepted?

  • @SpeakSatvik
    @SpeakSatvik 4 ปีที่แล้ว

    why we created the trap state, why we not put it to the final state to stay their whenever any input comes?

  • @asmaa4721
    @asmaa4721 4 ปีที่แล้ว

    Thanks it's was helpful , but please can you explain other example about AND

  • @PlRATE
    @PlRATE 3 ปีที่แล้ว +1

    why not just loop the 0 on c and loop 0,1 on the final states?

  • @deekshit_Shetty
    @deekshit_Shetty 3 ปีที่แล้ว

    Thanks sir it helped me alot 😁

  • @24_nirmalodedara96
    @24_nirmalodedara96 3 ปีที่แล้ว

    sir if state have not transition edge to go othew state for any input it is not DFA ?? this is true ??

  • @sandeepsingh87
    @sandeepsingh87 3 ปีที่แล้ว +1

    Are dead states also known as hang states?

  • @alexwilson8269
    @alexwilson8269 5 ปีที่แล้ว

    Would this no longer be deterministic? C has an option for when there is a 1 inputted, but no option for when 0 is inputted?

    • @alexwilson8269
      @alexwilson8269 5 ปีที่แล้ว

      Never mind, I just needed to finish the whole video 😅

  • @gabrielsales7402
    @gabrielsales7402 4 ปีที่แล้ว +1

    But '1100' should be accepted, as it has at least one '1' followed by a '0' right there in the middle.
    Also '11010' should be accepted, for the same reason (it has a 1 followed by a 0).
    So a better, more descriptive definition for the language should be "Accepts the string 01 or a string that starts with a 1, followed by any amount of 1, ending with only one 0." That was a big description, but it at least somehow covers it.

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว +1

      Yes, there's a problem of clarity in the statement. The fact that it has not to be a sub string could have been stated better.
      L = {Accepts the string 01 or a string of at least one 1 ended by exactly one 0.} This could have been a more clear representation of the DFA.

    • @tusharmahajan-ng2ch
      @tusharmahajan-ng2ch ปีที่แล้ว

      you're right!

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

      @@tusharmahajan-ng2ch thanks I’m always right

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

    What about 11010
    It contains 1 followed by 0
    it should be accepted according to the logic...
    But on this DFA it will be rejected and end up in X.

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

    if 1001 then b also should send 0 in dead state am i right??

  • @sahinislam1163
    @sahinislam1163 8 หลายเดือนก่อน

    Is this also work for 101?

  • @fayssalelansari8584
    @fayssalelansari8584 4 ปีที่แล้ว

    before changing the map with "001" the last 01 should match ?

  • @abhinavs2484
    @abhinavs2484 7 ปีที่แล้ว +3

    Or you can simply write = 1*0 for the DFA

  • @shinigamiryuk4183
    @shinigamiryuk4183 3 ปีที่แล้ว

    my teacher plays your videos in lectures

  • @emimini1737
    @emimini1737 6 ปีที่แล้ว

    Hi sir, When the input is 1 in D what about sending back to B.Still the condition keep right?

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

      At first, I thought you were right, but no, if that happens, the string will have more 0's in between (Like 11010 or 101010) and I think that will not be accepted. They only want one 0, at the end.
      Lol, why am I answering this, you posted this a year ago, you're probably done with your exams for this subject. Hopefully, this will help someone else, though.

    • @shivamchhabra7135
      @shivamchhabra7135 4 ปีที่แล้ว

      @@RishikavsAnnie haha 😃😃 , so nice of you

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

      @@RishikavsAnnie

  • @savaj4756
    @savaj4756 2 หลายเดือนก่อน

    1:49 DJ Khaled : another one and another one

  • @vamshikrishnam9206
    @vamshikrishnam9206 4 ปีที่แล้ว

    what is the use of dead state y we are mentioning it.
    we can complete dfa without dead state

    • @pcv910
      @pcv910 4 ปีที่แล้ว

      Every state must contain transition.
      Here for D,E has no transitions.
      And for C don't have 0 transition.
      So we used dead state..
      And dead state also must have transition, so used self loop..

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

    Sir why c don't have self loop

  • @aayushm9377
    @aayushm9377 7 ปีที่แล้ว

    The string 010 contains atleast one '1' and is followed by a zero , it should be accepted but it goes to dead state?

    • @sujithneelakandankizhakill9222
      @sujithneelakandankizhakill9222 7 ปีที่แล้ว +3

      I believe the confusion is with the language. The language could be modified to {01, or string starts with one and ends with 0, which should be the only 0 in the string}

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว

      Here, the string 1111....10 (at least one 1 followed by 0 is not assumed to be a sub string, it just is at least one 1 followed by one 0. )
      For instance, 1110 will be accepted . But 11101 or 11100 will be rejected. So, stage D has to transition to Stage X to ensure rejection of the above mentioned strings. If stage D transitions to D itself, then 11101 and 11100 will both be accepted .
      If the case was that at least one 1 followed by a 0 was a sub-string(for example 11100 or 11101) then D should have transitioned to itself on 0 and 1 .
      The question is not about 01 or 111...10 being sub-strings .
      It either exactly has to be 01 or 111.....10 (n number of 1s followed by a 0, where n=1,2,3....).
      So, basically
      1110 accepted.
      11101 rejected.
      11100 rejected.
      01 accepted.
      010 rejected.
      010101 rejected .
      As we can see, the examples which have been rejected above have 1110 and 01 as sub strings , but since they are not the complete strings, they are rejected.
      That's the demand of the question.

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว

      Although, there's a problem of clarity in the statement. The fact that it has not to be a sub string could have been stated better.
      L = {Accepts the string 01 or a string of at least one 1 ended by exactly one 0.} This could have been a more clear representation of the DFA.

  • @wasimahmad775
    @wasimahmad775 6 ปีที่แล้ว

    Sir what about string (11010 ) here also 1 followed by 0 but it is in dead state. why?

    • @jyosthna3769
      @jyosthna3769 5 ปีที่แล้ว

      S .

    • @gabrielsales7402
      @gabrielsales7402 4 ปีที่แล้ว

      Yeah, that's what I'm thinking. I guess the language definition is off. We could try to come up with a better definition for this state machine. Maybe something like "Accepts the string 01 or a string that starts with a 1, followed by any amount of 1, ending with only one 0." That was a big description, but it at least covers it.

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว

      @@gabrielsales7402 Here, the string 1111....10 (at least one 1 followed by 0 is not assumed to be a sub string, it just is at least one 1 followed by one 0. )
      For instance, 1110 will be accepted . But 11101 or 11100 will be rejected. So, stage D has to transition to Stage X to ensure rejection of the above mentioned strings. If stage D transitions to D itself, then 11101 and 11100 will both be accepted .
      If the case was that at least one 1 followed by a 0 was a sub-string(for example 11100 or 11101) then D should have transitioned to itself on 0 and 1 .
      The question is not about 01 or 111...10 being sub-strings .
      It either exactly has to be 01 or 111.....10 (n number of 1s followed by a 0, where n=1,2,3....).
      So, basically
      1110 accepted.
      11101 rejected.
      11100 rejected.
      01 accepted.
      010 rejected.
      010101 rejected .
      As we can see, the examples which have been rejected above have 1110 and 01 as sub strings , but since they are not the complete strings, they are rejected.
      That's the demand of the question.

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว

      Although, there's a problem of clarity in the statement. The fact that it has not to be a sub string could have been stated better.
      L = {Accepts the string 01 or a string of at least one 1 ended by exactly one 0.} This could have been a more clear representation of the DFA.

  • @shreeyadhole5755
    @shreeyadhole5755 4 ปีที่แล้ว

    Why is it so that when C gets input 0 it goes to dead state why it does not remian in itself.. like state B

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

    why has c has only one 1 string ? why dont have 0 output?

  • @ahmetkarakartal9563
    @ahmetkarakartal9563 3 ปีที่แล้ว

    thank you so much

  • @tshepomatshisevhe4656
    @tshepomatshisevhe4656 5 ปีที่แล้ว

    Does this mean State C in the previous video can have many a's and end up having something like aaaaaab then it goes to state D? That means the string won't be accepted.

    • @ayushsinghchauhan4121
      @ayushsinghchauhan4121 5 ปีที่แล้ว

      according to me, the ones he has taken besides the aabb must go to empty state... correct me if i m wrong and also suggest a example video for DFA...

  • @yashnarang637
    @yashnarang637 4 ปีที่แล้ว

    i think this will only accept two digit string which contains differ digits means only (01,10) thats it .

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

    How can we get slides?

  • @apporvaarya
    @apporvaarya 5 ปีที่แล้ว +3

    nice just few more to go: )

  • @anubhabsahu470
    @anubhabsahu470 4 ปีที่แล้ว

    00110 is same as 110 but 1st one is houng to the dead state. Could anyone please explain

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว

      Here, the string 1111....10 (at least one 1 followed by 0 is not assumed to be a sub string, it just is at least one 1 followed by one 0. )
      For instance, 1110 will be accepted . But 11101 or 11100 will be rejected. So, stage D has to transition to Stage X to ensure rejection of the above mentioned strings. If stage D transitions to D itself, then 11101 and 11100 will both be accepted .
      If the case was that at least one 1 followed by a 0 was a sub-string(for example 11100 or 11101) then D should have transitioned to itself on 0 and 1 .
      The question is not about 01 or 111...10 being sub-strings .
      It either exactly has to be 01 or 111.....10 (n number of 1s followed by a 0, where n=1,2,3....).
      So, basically
      1110 accepted.
      11101 rejected.
      11100 rejected.
      01 accepted.
      010 rejected.
      010101 rejected .
      As we can see, the examples which have been rejected above have 1110 and 01 as sub strings , but since they are not the complete strings, they are rejected.
      That's the demand of the question.

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว

      Although, there's a problem of clarity in the statement. The fact that it has not to be a sub string could have been stated better.
      L = {Accepts the string 01 or a string of at least one 1 ended by exactly one 0.} This could have been a more clear representation of the DFA.

  • @rutujadamkondwar
    @rutujadamkondwar 4 ปีที่แล้ว

    can there be more than 1 dead state??

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

    Once you are dead you stay dead 😁 Great explanations and video series 🙏

  • @ChAkIrLbR
    @ChAkIrLbR 5 ปีที่แล้ว

    is the dead state a must ?

    • @pcv910
      @pcv910 4 ปีที่แล้ว

      Yes

  • @Learn2earn-M
    @Learn2earn-M 5 ปีที่แล้ว

    شكرا جدا🌷

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

    how can B store so many instances of '1' as said by you that DFA's have very low memory?

    • @yuribr84
      @yuribr84 5 ปีที่แล้ว +4

      I doesn't store any instances. All state B knows is "input string started with '1' and no '0' has appeared yet".

  • @manavmalhotra8513
    @manavmalhotra8513 5 ปีที่แล้ว +5

    what if the state 'C' gets 0?

    • @amitshaw8788
      @amitshaw8788 5 ปีที่แล้ว

      it will get trapped.

  • @Ankit-we8ym
    @Ankit-we8ym 8 ปีที่แล้ว

    will you cover gate sllabus

  • @akshattrivedi2137
    @akshattrivedi2137 4 ปีที่แล้ว +1

    It's not even a DFA yet , you've not defined the transitions over the final states and also a lot of other transitions. And we can only call a FSM a DFA when on all the states have all the transitions defined.

    • @Asma-il3uh
      @Asma-il3uh 2 ปีที่แล้ว

      Yeah!!
      It's not deterministic.
      I was looking for this comment.

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

    So this is how you make spaceships in games

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

    Awesome Videos.❤
    .
    .
    The employee to entrepreneur add has started to appear everywhere and it's irritating.

    • @AliAhmed-gg1tz
      @AliAhmed-gg1tz 5 ปีที่แล้ว

      randi k bachay ko kuch nahi aata. fail kara dy ga

  • @rohitippili3834
    @rohitippili3834 6 ปีที่แล้ว

    Thanks sir

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

    In other words , this DFA accepts strings which doesn't contain 2 consecutive 0's(00 ).

  • @daviswang7104
    @daviswang7104 7 ปีที่แล้ว +3

    Actually this DFA doesn't represent at least '1' followed by a '0', if so, the string '010' wouldn't fail to the dead state, in fact, it represent a string start by '1', ended by '0', at the same time, whose content be filled with 0 to Inf numbers of '1'.

    • @ziliestarrive
      @ziliestarrive 6 ปีที่แล้ว +1

      You mean ONE 0 and any number of 1 greater or equal to one right? Otherwise you could have something like 11010 but then it goes to dead state.

    • @vishalkumarjha3368
      @vishalkumarjha3368 3 ปีที่แล้ว

      Yes, there's a problem of clarity in the statement. The fact that it has not to be a sub string could have been stated better.
      L = {Accepts the string 01 or a string of at least one 1 ended by exactly one 0.} This could have been a more clear representation of the DFA.

  • @donglequang2248
    @donglequang2248 6 ปีที่แล้ว

    hi teacher,
    001, if no X is predicted?

  • @kedarsambhus3623
    @kedarsambhus3623 7 ปีที่แล้ว

    Isn't this DFA incomplete? State C doesn't have a transition for input 0 and states D and E don't have any transitions.

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

    so, basically this dfa accepts 01+{1*0} ??

    • @RishikavsAnnie
      @RishikavsAnnie 4 ปีที่แล้ว

      I think so

    • @sattamkh
      @sattamkh 3 ปีที่แล้ว

      no, the right answer is (01| 1^+ 0)

    • @sattamkh
      @sattamkh 3 ปีที่แล้ว

      the number 1 should be (one or more => (+) ) not (zero or more => (*) )

  • @lokesh_pathak248
    @lokesh_pathak248 5 ปีที่แล้ว +1

    this is an example of nfa too

    • @-Mounika-lh1dw
      @-Mounika-lh1dw 5 ปีที่แล้ว

      S it's not example for dfa i think soo
      Bcz for dfa it must have 2alphabets that means 0,1 for ever state right

  • @KickassCoders
    @KickassCoders 7 ปีที่แล้ว

    sir what it's mean, 0 is divided by 5 and 1 is divided by 3

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

    Can I have a dead state in dfa

  • @ZainAli-xw8es
    @ZainAli-xw8es 3 ปีที่แล้ว

    language should be " accept 0,1 or string start with 1 and end with 0."

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

    'The dead may never die.' Sounds familiar 🏹⚔️🗡️

  • @bikoteedesigns
    @bikoteedesigns 5 ปีที่แล้ว +1

    Please can there be tutorial on how to draw a DFA to recognize source program?

  • @Ankit-we8ym
    @Ankit-we8ym 8 ปีที่แล้ว

    sir I am following TOC lectures they are very gud,do you teach any other sub of cse

  • @LethalChicken77
    @LethalChicken77 ปีที่แล้ว +6

    Bad video, every state needs defined transitions for all symbols in the alphabet

  • @Er.meghajain
    @Er.meghajain 7 ปีที่แล้ว +1

    woow too good 👌

  • @akash.manna.
    @akash.manna. 10 หลายเดือนก่อน

    How can it be DFA? Isn't it NFA?

  • @nishanttiwari9736
    @nishanttiwari9736 4 ปีที่แล้ว

    is that diagram really a dfa????

  • @ishaandawar7373
    @ishaandawar7373 7 ปีที่แล้ว

    Can't we say string 01 and string with atleast one 1 and ending with 0

    • @LeetCodes
      @LeetCodes 7 ปีที่แล้ว +1

      it needs to begin with 1, have consecutive undetermined 1's and then end with 0, so something like L1 = {Accepts string '01' or any string beginning with one or more '1' while ending with '0'}, is a more accurate Language for this example DFA

  • @rns031
    @rns031 5 ปีที่แล้ว +1

    L={either starting with 01 or ending with 10}

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

    The Strings From Final State Will Never Be Transferred Or Accepted In Dead State.

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

    6:14

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

    Is this not an NFA? Or at least an incomplete DFA. Edit: Oh he explained this but that’s so weird to start with an incomplete dfa

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

    Where is mod based question??

  • @continnum_radhe-radhe
    @continnum_radhe-radhe ปีที่แล้ว +1

    ❤❤❤

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

    X is like in Loki S1 void where everythigh is sent