Is Graph Bipartite? | leetcode 785 | Hindi

Поділитися
Вставка
  • Опубліковано 11 жов 2024
  • liked this video? Click here / @codebix1096 join our facebook group :- / 258049468776636
    problem :- leetcode.com/p...
    code :- github.com/luc...
    graph playlist :- • Graph Intoduction

КОМЕНТАРІ • 27

  • @yogeshdharya3857
    @yogeshdharya3857 5 місяців тому

    Channel Intro 🔥🔥🔥🔥🔥🔥

  • @ramankr0022
    @ramankr0022 Рік тому

    beautiful colors. very helpful explanation.

  • @rohankanotra6205
    @rohankanotra6205 2 роки тому

    sable badiya channel

  • @abhijitbiradar
    @abhijitbiradar Рік тому

    your explanation is from basic, a lemon person can also understood. Thanks a ton for Leetcode playlist

  • @ravishraj664
    @ravishraj664 2 роки тому +2

    one mistake 8:36 In queue there should be 3 instead of 2.

  • @sharuk3545
    @sharuk3545 3 роки тому

    awesomeee sir

  • @minakshikudalkar557
    @minakshikudalkar557 4 роки тому +5

    I almost gave up on this question! Great explanation, thanks!!

  • @basiljacob3894
    @basiljacob3894 3 роки тому +1

    Wonderful explanation . I liked the way you sunk your code explanation along with the diagrammatic explanation . This way i understood the code clearly

    • @codebix1096
      @codebix1096  3 роки тому

      Glad it helped!
      Follow our linkedin page for regular updates www.linkedin.com/company/codebix/?viewAsMember=true

  • @ashwanikumar4288
    @ashwanikumar4288 3 роки тому

    This is awesome. I simply could not understand the logic behind coloring but thanks to you, now I fully understand it. Keep uploading!

  • @ChandraShekhar-by3cd
    @ChandraShekhar-by3cd 2 роки тому +1

    @codebix Thanks a lot for such an amazing explanation. Sir pls keep uploading more videos on DS Algo and system design as well. We all are proud of you!!

  • @prathammeghani6128
    @prathammeghani6128 4 роки тому

    Best explanation ever......

    • @codebix1096
      @codebix1096  4 роки тому

      Thanks Pratham :)
      please share this channel with your friends

  • @abhay6124
    @abhay6124 4 роки тому

    great sir , can you do backtrack problems here also

  • @pranjalsharma499
    @pranjalsharma499 4 роки тому

    Nice sir... Keep on making more videos on Graphs

  • @mayanknautiyal4869
    @mayanknautiyal4869 4 роки тому

    There could not have been a better explanation for this topic. One ques though Even vertex cycle always guarantee bipartisanship?
    For python users:
    class Solution:
    def isBipartite(self, graph: List[List[int]]) -> bool:


    colors = [0]*len(graph)

    for i in range(len(graph)):

    if colors[i]:
    continue

    queue = []
    queue.append(i)
    colors[i] = 1

    print(queue)
    while queue:
    front = queue.pop(0)
    for i in graph[front]:
    if colors[i] == 0:
    colors[i] = -colors[front]
    queue.append(i)


    if colors[i] == colors[front]:
    return False
    return True

    • @codebix1096
      @codebix1096  4 роки тому

      no i said odd cycle always guarantee bipartite graph.. other then that we need to check

    • @nemesisanims7401
      @nemesisanims7401 4 роки тому

      @@codebix1096 I guess you mean odd cycle guarantee 'No Bipartite Graph' Possible

  • @redwanniloy2068
    @redwanniloy2068 3 роки тому

    Isn't 0's childs are 1 and 3?
    But u put 1 and 2 in the queue!!!!!!

    • @mukulmangla632
      @mukulmangla632 3 роки тому

      yaa i also got confused there 😀

    • @TuringTested01
      @TuringTested01 Рік тому +1

      itna dimag to tere mein khud bhi hona chaiye, patthar chabata hai kya

    • @redwanniloy2068
      @redwanniloy2068 Рік тому

      @@TuringTested01 ronaldo ka hater patthar chabate hein ye to sure hein bhai

  • @techgamer1333
    @techgamer1333 4 роки тому +1

    One MisTake Brother on 18:07 *Array Index [2] ==1* it should be * 1* , Other wise ** its *Adjacent Vertex index[1]== -1* and * index[3]==-1* are same colour