The Backtracking Blueprint: The Legendary 3 Keys To Backtracking Algorithms

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

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

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

    Table of Contents:
    Beginning The Backtracking Discussion 0:00 - 1:08
    The 3 Keys To Backtracking 1:08 - 2:40
    The Choice: Defining Our Decision Space 2:40 - 5:50
    The Constraints: Directing Our Recursion 5:50 - 7:42
    Our Goal: When Recursion Bottoms Out 7:42 - 9:22
    Lesson Summary 9:22 - 10:52
    How Do We Know When We Can Use Backtracking 10:52 - 12:07
    Wrap Up 12:07 - 13:25
    I don't like the word "blueprint" for these problems. There are patterns, I agree. But memorization of code snippets and patterns will rob you of true learning. You won't learn how to think on your own. Don't learn templates, know what is going on deeply.
    The code for the Sudoku solver problem is in the description.

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

      @shaurya pratap singh Depends. Like...this is hard to answer. What I focus on is Big N companies and these kinds of questions. For any other job in tech I really am not sure...it depends what you want to do.
      But yes, if you can do these then it basically proves you have the intellectual prowess to learn any tools used on the job.
      Much much easier to go from being a computer scientist to being a software engineer, than to go from web development to being a computer scientist.

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

      @shaurya pratap singh sure

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

      A video on Dynamic programming blueprint as well

    • @bberger7858
      @bberger7858 4 ปีที่แล้ว +18

      There is no code in the description

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

      I can't find the link to your code

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

    bro can you all make every video from now on like this?..... i love the graphics .... putting the code on the screen is major key

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

      I wish I could. This took 7 hours. I...I really wish I could make everything top notch and it is annoying...but yeah I will continue to mix things up :)

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

    “Our for loop is for exploration in the stack frame” thanks for phrasing it like that it makes a lot of sense to me now

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

      yeah, I knew people would like that. I had that sentence circulating in my brain before I did this video (I had no script)...so I made sure I said it.

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

    I am so happy I found this channel! Dynamic Programming scares me but I am determined to combat that scare and these videos will help for sure. Thanks heaps :D

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

    i love that your torso just blends into the background with the white shirt and you are just a benevolent set of floating body parts teaching us how to not fail finals tomorrow.

  • @Anand-wi4yb
    @Anand-wi4yb 5 ปีที่แล้ว +11

    0 Dislikes tells that how much people like the way you explain.

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

    Hi Ben, You are really doing great job. The way you explain the problem, make it very easy to understand and sink.It not only help us to understand the thought process but also bringing interest in to solving this type of problems. Your video's are the best among all the you tube videos which i have seen so far. I really appreciate you and your friend's effort for bringing out such a awesome contents.

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

      It's just me now, but yeah...thanks :)

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

    Sometimes we see things that are so splendid that we are out of words to express.And right now I am.
    Thanks for this awesome video.

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

    This is how you become humble and knowledgable at the same time

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

    That sudoku is wrong, there are two 1s on column 4!!!

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

      I don't remember what you are referencing

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

      there are also two 8s in that same column lmao

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

    Beautiful explanation. Almost feels criminal that it isn't a paid course or content..I struggled for sometime on most DP tutorials mostly because they were focusing on what to do and not why.

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

      hahah, I do have a paid course that I'm growing right now. But yeah, all the videos here are the property of the internet and mankind now.

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

    where is the code. it is not in the description :/

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

    Not the hero we deserve, but the hero we need...

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

    I love your teaching approach, not directly jumping to solutions but showing entire thought process.

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

    I absolutely love your videos. Your explanations are just spot on. Your videos are the reason why I feel like I am getting a hold of difficult topics like recursion, DP, and backtracking. Great work dude!

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

    I watched this video about a month ago when I was trying to get my head around backtracking but couldn't understand much. After solving a bunch of problems on Leet Code over the past month, I'm watching this video again, and surprisingly, it makes a lot more sense now xD
    Thanks a lot!

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

      Glad it was helpful! 😄 Also check out our FREE DSA Interview Prep Mini-Course - backtobackswe.com/ 🎉

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

    These three keys are very useful inorder to find a pattern to solve any backtracking the problem !...Thanks a Ton bro !

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

    Can you always avoid backtracking and instead use simple recursion with an "if statement" to "stop yourself making mistakes"? E.g, I recurse every possibility and if a possibility doesn't' work out you just ignore it..?

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

      im not sure - maybe not? dont know

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

    Is that you, Lewis Hamilton?

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

    I love the clarity of your video! Thank you very much!

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

    Thank you for providing a template for the backtracking problems. As an aspiring software engineer, this helps a lot!

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

    Thanks for making these videos! Your videos are always really engaging and really well-thought out. I hope you keep going with this channel; it's really invaluable to the SWE community. I feel this one particularly was really great because it really helps with building the mental model needed to approaching backtracking. You generally do a great job at this in your other videos, but I'm really glad you took the time to dedicate a whole video on the general approach. It's always great to be able to solve problems, but even more important to build the right intuition.

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

      sure, I try my best....most of the time :)

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

    When TH-cam suggested this video for Backtracking, I was wondering why Lewis Hamilton is explaining Backtracking 🤔 😳.
    But you certainly didn't disappoint. Thanks for the great explanation 👍

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

      haha! thanks. Hoping to see Lewis back on the f1 track

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

      Subscribe to our DSA course with a flat 30% discount for some amazing content b2bswe.co/3HhvIlV

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

    I like your content. I appreciate your enthusiasm from your voice and smile.

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

      Thank you! Please enjoy a special code from us - backtobackswe.com/checkout?plan=lifetime-legacy&discount_code=IneluctableConcomitant 🎉

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

    Pls post video for unique path III (LC 980). There is no good explanation on this problem anywhere on youtube.

  • @itsamankumar403
    @itsamankumar403 4 หลายเดือนก่อน +1

    The Empty_Entry should be inside the for loop , isn't it ?

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

      I think it should be outside. When you are backtracking you remove the latest update and return False, so when you go back to the caller of the function it sees that element of the board as empty

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

    I like ur way of thinking and asking questions during solve any problem

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

    Lol "i don't think that video is that good..." nah YOU ARE AMAZING MAN IF I PASS MY INTERVIEW ON FRIDAY A LARGE CREDIT WILL BE TO YOU. Thank you! ❤️

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

    Yes, something can be done ... We will set up an organization to boycott high-tech companies with particularly difficult questions

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

    like for Masai Student from UNIT 3

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

    Really awesome videos, watched most of your DP's, annoyed my friends sharing them all the links. Hope you & your channel achieve greater success!

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

      thanks for sharing us, best thing anyone can do to help. And thanks, we are working on it.

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

    "I kind of just went for it ..and talked a lot " . That's honestly funny.. nice videos my friend

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

    THIS MAN IS A LITERAL LEGEND. May you be blessed with glory in all three worlds.

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

      I am normal

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

      @@BackToBackSWE hahahaha ik ik. honestly thanks for giving back to the community.

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

    Man, your videos are really helpful. The way you explain it, your passion and your attitude is pure gold.

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

      Thanks! you could always try the 5 day free mini course for some awesome content - backtobackswe.com/

  • @pranavkrishna3048
    @pranavkrishna3048 6 หลายเดือนก่อน

    def solve(row, col, board):
    n = len(board)
    m = len(board[0])
    # Base case: if we've reached the end of the board
    if col == m:
    return True
    # Recursive case: try placing a value in the current cell
    for value in range(1, 10): # Try values from 1 to 9
    board[row][col] = value # Place the value in the current cell
    if validPlacement(row, col, board): # Check if the placement is valid
    # If the placement is valid, recursively solve for the next cell
    if solve(row, col + 1, board):
    return True
    # If the placement is not valid or does not lead to a solution, backtrack
    board[row][col] = 0 # Reset the cell to empty
    # If no value leads to a solution, return False
    return False
    def validPlacement(row, col, board):
    # Implement the logic to check if placing a value at the given row and column is valid
    pass # Placeholder, replace with your implementation
    # Example usage:
    # Initialize a 9x9 Sudoku board (as a list of lists)
    board = [
    [0, 0, 0, 0, 0, 0, 0, 0, 0],
    [0, 0, 0, 0, 0, 0, 0, 0, 0],
    [0, 0, 0, 0, 0, 0, 0, 0, 0],
    [0, 0, 0, 0, 0, 0, 0, 0, 0],
    [0, 0, 0, 0, 0, 0, 0, 0, 0],
    [0, 0, 0, 0, 0, 0, 0, 0, 0],
    [0, 0, 0, 0, 0, 0, 0, 0, 0],
    [0, 0, 0, 0, 0, 0, 0, 0, 0],
    [0, 0, 0, 0, 0, 0, 0, 0, 0]
    ]
    # Start solving from the top-left corner (row=0, col=0)
    if solve(0, 0, board):
    print("Solution found:")
    for row in board:
    print(row)
    else:
    print("No solution exists.")
    i think theres an error like we need to reset if placement is not valid here i see that its directly outside the fore loop means we reset every cell to 0 once every iteration s are done
    please corect me if im wrong

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

    Nice video man. I like your style of teaching, this is the first ever video of yours that I've watched and I like the casual style of teaching. It would be great if you could make videos that emphasize the guiding principle behind solving a problem and then share ways to attack the problem as well, in a direct way. Thanks and Cheers!

  • @dawitz362
    @dawitz362 วันที่ผ่านมา

    Thanks for the best explanation. You have got my subscription and like.

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

    How can I be as smart as you?

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

      I am of average intelligence and was naive enough to think I could teach others so I did and gained normal competence.

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

    Is it just me or using value instead of i feels so illegal😂

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

    Finally someone who could explain this to me in a way I actually understood...

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

    you're a legend mate..better explanations than 95% of my uni profs

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

      Give me 1-3 years...the legend will continue.

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

    Honestly, effects are amazing I can see that you put too much effort and it deserves respect. But explanation, I don't your expressions are good but something is missing. I don't know what it is but something is missing. But thanks anyway.

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

    One thing missing from this video is explaining why the time complexity is what it is, what is the space complexity and, most importantly, WHY?

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

    Hi, I can't find the full code in the description :/. Can someone comment under my comment the full code please?

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

      The repository is deprecated - we only maintain backtobackswe.com.

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

    I am creating a sudoku grid filler (from empty cells) and using this approach. But after being able to fill two three rows with all constraints (of rows, columns and blocks) the program doesn't run. With any one constraint it works, but with all it goes whacky. Any help?

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

      I can't debug your code

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

      @@BackToBackSWE Yup. Totally get that. :) Thanks anyway.

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

    This is hands down the best description I've heard on helper method recursion/backtracking.

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

    is there a precursor video to this? i feel like i understood nothing from your video.

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

    You should explain how to backtrack a wrong choice. Too much conceptual. There is no explanation here.

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

    What's the difference between a DFS and Backtracking problem?

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

      DFS is a search methodology & backtracking is more of a description of an algorithmic behaviour.

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

    can anyone here explain to me what is the difference between backtracking and depth first search , thanks

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

      Wikipedia has some crisp definitions.

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

    bad explanation about the purpose of the video based on the title, you just don't say : "well based on experience", it like almost you said nothing

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

    Where is the code sample in the description?

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

      The repository is deprecated - we only maintain backtobackswe.com.

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

    Just don't go down the Jarvis Johnson path... keep a balance between vlogs and vids like these

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

      hahahaha, this is funny but I think I should do whatever I want because this is my channel. I shouldn't listen solely to anyone but myself

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

    the title is general, but all the explanation is reliant on a very specific example. What if I don't know sudoko?

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

    Make the n-queen problem again please. U really helped me understand dynamic programming, thank you so much!

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

      Yeah I think I can explain it better today vs 1 year ago

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

    Can you give some link of the topic related problems in different online judges for practice .

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

      We have a lot of backtracking problems on backtobackswe.com (paywall)

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

    Is it easy or difficult to find one pattern (one solution) of 2500 or 5000 queens with Backtracking Algorithms?

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

      what do you mean?

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

      @@BackToBackSWE
      5-queen has 10 solutions (patterns)
      8-queen has 92 solutions.
      X-Y coordinate of one pattern (one solution) in 5-queen is, for example,
      (1,5), (2,2),(3,4),(4,1) and (5,3) as follows.
      Qxxxx
      xxQxx
      xxxxQ
      xQxxx
      xxxQx
      It is easy to find out this one pattern.
      Does it take too much time to find out one pattern in 2500-queen or 5000-queen?

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

    where's the code? :c good video thanks!!!!!!

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

      The repository is deprecated - we only maintain backtobackswe.com now. and thanks

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

    The content you are creating is valuable. Educational and entertaining and delivered a way that makes it stick in memory. The approach to the topics makes it easy to grasp and remember the base concepts and tool sets which gives the confidence to handle any interview question. Being able to quickly classify the type of problem and the tool set, algorithm and data structure to address it makes all the difference. If you could somehow show how to implement the code on white board would be cool. Also, some sample interview role playing with be great.

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

      Yeah, I have a video coming out in a little that will address the future of this project.

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

    Very nicely done. One request. When you screen reference the previous related videos, could you add a link in your intro text along with the other excellent links you provide...I'm reviewing them all in sequence to help me work through these problems and leetcode questions.
    Your explanations provide great insights and I REALLY appreciate all of the effort you have placed in these discussions. Thank you!

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

    i didn't knw abt backtracking at all and zis helped me on understanding string permutation more. Soo thank you.

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

    doing great job man!.... It's just my second video that i watched..... I really have respect for you .

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

    I'm wondering if you could store the decision space in an array or hashset. So each stack frame would only have to loop through a _maximum_ of N choices, but a minimum of 1 choice.

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

      could you elaborate?

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

      If you're at cell (3,2) - 3rd row, 2nd column. You already know placements (0,2), (1,2), (2,2) and similarly (3,0), (3,1). So you need not search for the decision space that is already allocated to those cells. This optimisation would take up a lot of space though - so it may not be worth it.

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

    I know I have a backtracking problem when I am completely stuck trying to do it

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

    Love the effects in the videos, helps us understand

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

    Bro, I have this constant doubt in my mind. can we apply DP on a matrix where we can reach a point from all 4 directions?? When can we apply DP vs when should we apply backtracking???

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

      Not sure about the problem you are describing in the first part of your comment. As to the second part, it depends on the problem. DP is defined by subproblems that explicitly overlap and can reduce the time of a complete search or pruned search backtracking algorithm.

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

      @@BackToBackSWE I will share a leetcode problem with you maybe that will work better. leetcode.com/discuss/interview-question/476340/Google-or-Onsite-or-Min-Modifications
      I see many people coming up with a DP solution, but can we apply DP in this question??
      I know 0-1 BFS works perfectly fine but then as another alternative

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

    Hey Ben , your explanation is awesome, can u please explain optimal game strategy question. From recursion to DP.

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

      yeah, I may throw that into this site: twitter.com/thebigoguide

  • @RiteshSingh-lo9cn
    @RiteshSingh-lo9cn 5 ปีที่แล้ว +1

    first time on this channel and subscribed it... Awesome way of teaching... Request to everyone: Share this video more nd moe

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

      ha thanks, we have a course where I'm posting more videos like this, check it out

  • @youareunderarrest.3173
    @youareunderarrest.3173 4 ปีที่แล้ว +1

    Check out Stanford's marty stepp backtracking videos.

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

    where is the code? i can't find it!

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

      Do check out backtobackswe.com/platform/content

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

    Best explanation I've found so far. Thank you man

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

    this video is one of the best i have ever seen on teaching skills.

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

      thanks

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

      @@BackToBackSWE I today got placed at Wells Fargo and I am here to say thank you to you. From you, I have learned the most important technique that is how to approach a problem. Thanks again and keep sharing your knowledge

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

    interesting that its exactly the same sudoku as in the computerphile video

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

      it is an image from wikipedia: en.wikipedia.org/wiki/Sudoku

  • @ТимурБелянин-й3ф
    @ТимурБелянин-й3ф 6 หลายเดือนก่อน

    Thank you dear man for your clear explanations! Hello from Russia!

  • @PradeepKumar-ie3vu
    @PradeepKumar-ie3vu 5 ปีที่แล้ว +1

    your way of teaching is damn Great..plz reorder your videos according to topics properly

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

    Good stuff! It is a pitch my uni 'teacher' is using your material instead of doing his own . I feel that I should be giving you the tuition fee not to the university of York.

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

      Hahaha!! 😀
      Please do recommend us to your family and friends 😀
      and do check out backtobackswe.com/platform/content

  •  หลายเดือนก่อน +1

    This is amazing

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

    I don't know whether I told you this before, but your video are reallllllllllly great!

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

    Thanks man, this help me solve leetcode 79 word search

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

    Hey just wanted to let you know that this video is INCREDIBLY helpful. I had an onsite interview with Google and this legit helped me solve 3 out of the 5 questions they asked me. Without ever seeing the problem before, I used this methodology and was able to solve the problems. HUGE thanks

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

    where is the code for suduko solver

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

      The repository is deprecated - we only maintain backtobackswe.com.

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

    Well said at the end!

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

      What did I say? Long time ago

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

      Back To Back SWE
      Your determination to save those people suffer from the tech interviews!

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

    When you “reset” the choice with board[row][col]=EMPTY_ENTRY, shouldn’t this line be under an else block inside the for loop? Currently you have it outside the for.

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

    do a video JUST like this on permutation algorithm

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

    Can you send a index variable that marks where the last one came. So you dont reiterate through 1-9. Seeing as if the row failed on 1-6, its going to fail again and u'll be doing extra 6 loops.

  • @KY-cl9gi
    @KY-cl9gi 5 ปีที่แล้ว +3

    learn a lot from you!

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

    You are real! That's all I can say! stay real man!!!

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

    13:13 Gold.

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

    Wow, this video really opened a new way of looking at the problems. Thank you and keep making videos!

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

    Hey man, recently found your channel and I absolutely love your teaching style. The quality of the videos have been getting better, too. I've been trying to practice more leetcode for interviews and whatnot, but since I've only recently started, I'm struggling quite a bit. When you see a problem that you do not understand or just have no idea how to solve at all, at what point do you give up and look at the answer?

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

      Thanks, thanks, and it depends greatly. If I know the problem class I'll keep going. But if I am just 100% stumped for 20 minutes, with no leads to start (which that still happens), only then do I look at the answer. And then there are times I look at the answers very quickly, just to get a mass of questions in. Ummm...yeah this really depends.

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

    This was great. First time in your channel mate, and you have already earned another subscriber...
    Keep on making such videos, that'll help us looking at such algorithms from another perspective, and help you learn more as you make them! Thanks!

  • @ll-sz9fl
    @ll-sz9fl 4 ปีที่แล้ว +1

    You could solve the Sudoku with DP, it would be faster: O(n*m), where n and m are the height and width of the grid.

  • @falakchudasama9746
    @falakchudasama9746 4 หลายเดือนก่อน

    Good channels are often underrated man! I am glad I explored your channel and got a ton of quality information, hope your channel grows!!

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

    Thanks, Is the time complexity for this BIG(n^2 * log n)

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

    Thanks for the video. Really helpful for my efforts to pass an algorithms and data structures class in undergrad CS.

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

    Thank you so much, really clarified my doubts about the usefulness of backtracking. My university teacher should be learning from you how to explain algorithms.

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

    i would have watched only a handful of your videos. I liked only this one, I think

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

      nice

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

      @@BackToBackSWE What are the choice, constraints and goal for combination sum problem?
      leetcode.com/problems/combination-sum-ii/

  • @Hank-ry9bz
    @Hank-ry9bz หลายเดือนก่อน

    to master recursion, make sure that your first master recursion

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

    im confused with DP vs Backtraking?=(

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

    Thank you for the video! This was really helpful and made it easier for me to understand Backtracking!