Product
Pricing
Blog
Forum
NEW
Referral
Description
Solution
Discussion
Submissions
Ask AI
AI Insights
Quick Summary
Determine the minimum number of coins required to reach a target amount from given denominations.
Return the exact quantity of each coin type used in that optimal combination.
Return an empty array if the target amount cannot be formed.
What This Tests
Dynamic programming state definition and recurrence relations
Reconstructing solutions from computed DP states
Handling boundary conditions like zero targets and unreachable sums
Managing unbounded resource allocation efficiently
Common Patterns
Dynamic Programming
Collapse
Hint 1
Hint 2
What Interviewers May Ask Next
Report
Report seen similar question in interview
Ask AI Assistant
Ask AI Assistant
Ask me anything about this coding question!
python
Auto
Debug
Run
Submit
Test Cases
Input
Output
Expected