Coin Change - Leetcode 322 - Dynamic Programming (Python)

Sdílet
Vložit
  • čas přidán 20. 08. 2024
  • Master Data Structures & Algorithms for FREE at AlgoMap.io/
    Code solutions in Python, Java, C++ and JS for this can be found at my GitHub repo here: github.com/gah...
    Complete DSA Pathway Zero to Hero: • Data Structures & Algo...
    Please check my playlists for free DSA problem solutions:
    • Fundamental DSA Theory
    • Array & String Questions
    • 2 Pointers Questions
    • Sliding Window Questions
    • Binary Search Questions
    • Stack Questions
    • Linked List Questions
    • Tree Questions
    • Heap Questions
    • Recursive Backtracking...
    • Graph Questions
    • Dynamic Programming (D...
    My Data Science & ML CZcams Playlist: • Greg's Path to Become ...
    Learn Python and Data Science FASTER at mlnow.ai :)
    Support the content: / @greghogg
    Follow me on Instagram: / greghogg5
    Connect with me on LinkedIn: / greghogg
    Follow me on TikTok: / greghogg5
    Coursera Plus: imp.i384100.ne...
    My Favorite Courses:
    Data Structures & Algorithms:
    - UCalifornia San Diego DSA: imp.i384100.ne...
    - Stanford Algorithms: imp.i384100.ne...
    - Python Data Structures: imp.i384100.ne...
    - Meta Coding Interview Prep: imp.i384100.ne...
    Python:
    - UMichigan Python for Everybody: imp.i384100.ne...
    - Python Mastery from MLNOW.ai: mlnow.ai/cours...
    - Google IT Automation w/ Python: imp.i384100.ne...
    Web Dev / Full Stack:
    - Meta Front-End Developer: imp.i384100.ne...
    - IBM Full Stack Developer: imp.i384100.ne...
    - Meta Back-End Developer: imp.i384100.ne...
    - John Hopkins HTML, CSS & JS: imp.i384100.ne...
    - IBM DevOps: imp.i384100.ne...
    Cloud Development:
    - AWS Fundamentals: imp.i384100.ne...
    - GCP Cloud Engineer: imp.i384100.ne...
    - Microsoft Azure Fundamentals: imp.i384100.ne...
    Game Development:
    - Michigan State Unity Development: imp.i384100.ne...
    - UColorado C++ for Unreal Engine: www.coursera.o...
    SQL & Data Science:
    - SQL by MLNOW.ai: mlnow.ai/cours...
    - Python for Data Science by MLNOW.ai: mlnow.ai/cours...
    - Google Data Analytics: imp.i384100.ne...
    - IBM Data Science: imp.i384100.ne...
    - IBM Data Engineer: imp.i384100.ne...
    Machine Learning & AI:
    - ML Mastery at MLNOW.ai: mlnow.ai/cours...
    - ML w/ Andrew Ng: www.coursera.o...
    - Deep Learning w/ Andrew Ng: imp.i384100.ne...

Komentáře • 18

  • @GregHogg
    @GregHogg  Před 27 dny +1

    Master Data Structures & Algorithms For FREE at AlgoMap.io!

  • @tarilonte
    @tarilonte Před 9 dny

    Your explanation is cristal clear! Thanks a lot for this great video!

  • @ibraheem_Zain
    @ibraheem_Zain Před 2 měsíci +3

    That was clear as sun and helpful even if you use python.
    Thanks sir you are awesome 👍😎❤

    • @GregHogg
      @GregHogg  Před 2 měsíci +1

      Awesome super glad it was helpful 😊

  • @darshandani1
    @darshandani1 Před 15 dny

    Great explanation ! Thanks !

  • @Alex-tm5hr
    @Alex-tm5hr Před měsícem +1

    Great job, imo better than neetcode's solution for the draw out part

  • @mansurischanov3204
    @mansurischanov3204 Před 25 dny

    thanks dude, this makes so much sense now!

    • @GregHogg
      @GregHogg  Před 25 dny

      Glad to hear it, this is a tricky one!

  • @new-anointingaremu3597
    @new-anointingaremu3597 Před 2 měsíci

    This explanation is great thanks a lot

    • @GregHogg
      @GregHogg  Před 2 měsíci

      Awesome happy to hear it!

  • @astronautgamer34
    @astronautgamer34 Před 2 měsíci +1

    plz explain coin change two it so hard for me to understand

    • @GregHogg
      @GregHogg  Před 2 měsíci +1

      I haven't solved this, I'll have to take a look at some point :)

  • @ayushdey5342
    @ayushdey5342 Před 2 měsíci +1

    what is the name of the blackboard app that you use to draw stuff? its really good looking

    • @GregHogg
      @GregHogg  Před 2 měsíci

      Yes it's awesome. It's miro

  • @adesopekingsley9967
    @adesopekingsley9967 Před 2 měsíci

    I was thinking 🤔
    We can sort reverse the list then pick the biggest number at index 0 then check if its greater than amount if false, then next but if true subtract from amount index. Check if result is present in the list [can use a set] if flase then call recursion using to repeat using result
    Example amount 12
    List=[1,4,5]
    List.sort(reverse=True)
    12>5.. therefore 12-5= 7
    7 not in list and greater than 5
    7>5 therefore 7-5=2
    2

    • @user-pn6kq5mx4z
      @user-pn6kq5mx4z Před 2 měsíci

      $4x3 =$12. So fewest is 3 coins. 5+5+1+1 is 4coins. it cover most but edge

    • @CGS9_
      @CGS9_ Před 2 měsíci

      @@user-pn6kq5mx4z always those edge cases that will get ya