 New update is available. Click here to update. Close
Topic list
Find Minimum Number Of Coins
EASY
15 mins 28 upvotes
Other topics
Problem solved
Skill meter Strings
-
- Matrices (2D Arrays)
-
- -
- Sorting
-
- Binary Search
-
- Stacks & Queues
-
- Trees
-
- Graph
-
- Dynamic Programming
-
- Greedy
-
- Tries
-
- Arrays
-
- SQL
-
- Binary Search Trees
-
- Heap
-
- Bit Manipulation
-
-
Solve problems & track your progress
Checkout your overall progress in every topic here
Become Sensei
in DSA topics
Open the topic and solve more problems associated with it to improve your skills
Check out the skill meter for every topic
See how many problems you are left with to solve for cracking any stage. Score more than zero to get your progress counted.

# Find Minimum Number Of Coins

Easy 0/40
Avg time to solve 15 mins
Success Rate 85 % Share 28 upvotes

## Problem Statement

#### So, Dora goes to a bank that has an infinite supply of each of the denominations to make a change for a given ‘Amount’ of money. As a cashier at the bank, your task is to provide Dora the minimum number of coins that add up to the given ‘Amount’.

##### For Example
``````For Amount = 70, the minimum number of coins required is 2 i.e an Rs. 50 coin and a Rs. 20 coin.
``````
##### Note
``````It is always possible to find the minimum number of coins for the given amount. So, the answer will always exist.
``````
Detailed explanation ( Input/output format, Notes, Constraints, Images ) ##### Sample Input 1
``````2
13
20
``````
##### Sample Output 1
``````3
1
``````
##### Explanation of Sample Input 1
``````For the First Test Case ,the minimum number of coins to make the change are 3 {1, 2, 10}.

For the second Test Case, only one coin {20} is required.
``````
##### Sample Input 2
``````2
50
96
``````
##### Sample Output 2
``````1
5
``````  Auto Console