The reason why write a blog, is because many problems in reality can be converted into a "change coin" problem and "0-1" knapsack problem. Therefore, need to understand carefully.
Secondly, some blogs and learning materials about greedy algorithm and dynamic programming are summarized in "reference material".
Difference:
In fact, the biggest difference is: to find coins in the problem of a certain type of coin can be selected multiple times. And for the 0-1 knapsack problem, an item is either selected, or not selected, after the election, it is "gone." Of course, there are 0-1 knapsack problems------------a complete knapsack problem--a certain (category) item has multiple, repeatable selection.
The second is the tradeoff of choice. 0-1 knapsack problem, there is a value attribute, in the choice of time, is to consider the maximization of value . The weight is equal to cost, while value is values.
For coins, it is not so complicated. From this point of view, it is easier to find a coin change problem. But it focuses on using fewer coins. so when considering other issues, judge whether it's about maximizing value or focusing on the least number.
Resources:
The correctness proof of greedy algorithm for partial knapsack problem
The correctness proof of some greedy algorithm for changing coins problem
The difference and relation between dynamic programming and greedy algorithm from the viewpoint of activity selection
Solving the longest common subsequence of two strings
Given an integer, the number of FIB numbers can be added to solve the integer at least
"Backpack Ninth Lecture"
https://www.zhihu.com/question/23995189 on the discussion of dynamic planning thought
Change coin problem with 0-1 knapsack problem difference