Algorithm Designex03e3_coin
Coin Change
087861a6-5851-4ea2-babc-7f6bbf2f93ce.cppC++
1// Loading code...Selected Submission
100 / 100
0.001s
1496 KB
DPImplementation
Time Comp.
O(amount * coinType)
Space Comp.
O(amount)
Readability
6/10
"The code calculates the minimum number of coins needed to make a given amount, which is a classic dynamic programming problem. It builds a DP table to store the minimum number of coins for each amount from 0 up to the target amount."
History
| Attempt | Points | Time ↓ |
|---|---|---|
| Try #1 | 100 | 2/25/2025 |