Sliding Puzzle || Graph theory

Поділитися
Вставка
  • Опубліковано 12 вер 2024

КОМЕНТАРІ • 19

  • @LegitGamer2345
    @LegitGamer2345 3 роки тому +13

    difficult questions become easy if done with pepcoding :)

  • @indiannightbot3598
    @indiannightbot3598 7 місяців тому

    Similar to AI 8 puzzle problem using heuristic value and informed search technique

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

    Sir hm direct agr vector ko set me store kra le to used is method see jyada TC aayega kya?

  • @nidhirathore7284
    @nidhirathore7284 2 роки тому +1

    Thank you sir for such a wonderful explanation 😄

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

    time complexity kya hogi iski...O(n*m) ????

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

    amazing explaination ,question boht easy bna diya sir aapne

  • @ece116pranaykumar4
    @ece116pranaykumar4 3 роки тому +2

    is backtracking the option

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

      you mean dfs , the complexity will go very high ,as in a call we will calc moves to if we started swap from some index ,then we will try for other,and everytime for a call it will solve completely ,and then we will compare min of all , here bfs is a lot bettter

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

    Thanks, sir.Amazing expalnation

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

    Ye graph k questions dp k memorization ki tarah lag rahe...btw best explanation🔥✨

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

      For better experience, visit nados.io, where you will get well curated content and career opportunities.

    • @cyberserker
      @cyberserker 2 роки тому +1

      memoization

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

    hatsoff

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

      Keep learning.
      And for better experience, visit nados.io, where you will get well curated content and career opportunities.

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

    bawa ji explained well but, coding mein bhand mar diya apny 😂. instead of detecting possible moves at time of execution you have add it in static fashion

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

    correct code in c++
    class Solution {
    public:
    int slidingPuzzle(vector& board)
    {
    queueq;
    string tar="123450";
    int r=board.size();
    int c=board[0].size();
    string act="";
    for(int i=0;i

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

      If you also want doubt support, you can consume same content on nados.pepcoding.com and a social media feed where your doubts will be taken care of.
      It is entirely free of charge.