Loop order determines whether order matters [mp]
Micro pattern¶
Description¶
Iterate choices outside totals to count unordered combinations and totals outside choices to count ordered sequences.
Problems¶
- 518. Coin Change II (Dynamic Programming)
- 377. Combination Sum IV (Dynamic Programming)