DP と Greedy の両方が最適部分構造を必要とします。違いは:Greedy には貪欲選択性(局所最適解が大域最適解である)も必要ですが、DP は複数の選択肢と重複する部分問題を検討する必要がある場合に必要です。
なぜ重要なのか
text
Optimal substructure? -- both need this
+ greedy-choice property holds? -> GREEDY (fast, one pass of choices)
+ must compare many sub-solutions / they overlap? -> DYNAMIC PROGRAMMING
