Coin Change - Leetcode 322 - Dynamic Programming (Python)
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...
Master Data Structures & Algorithms For FREE at AlgoMap.io!
Your explanation is cristal clear! Thanks a lot for this great video!
That was clear as sun and helpful even if you use python.
Thanks sir you are awesome 👍😎❤
Awesome super glad it was helpful 😊
Great explanation ! Thanks !
Great job, imo better than neetcode's solution for the draw out part
Yay!
thanks dude, this makes so much sense now!
Glad to hear it, this is a tricky one!
This explanation is great thanks a lot
Awesome happy to hear it!
plz explain coin change two it so hard for me to understand
I haven't solved this, I'll have to take a look at some point :)
what is the name of the blackboard app that you use to draw stuff? its really good looking
Yes it's awesome. It's miro
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
$4x3 =$12. So fewest is 3 coins. 5+5+1+1 is 4coins. it cover most but edge
@@user-pn6kq5mx4z always those edge cases that will get ya