US Currency Teller
Learn to convert an amount of money to its denominations.
We'll cover the following...
Challenge
In the USA, the currency is made up of US dollars ($) with bill denominations of $1, $2, $5, $10, $20, $50, $100, $500 and $2000. A bank is trying to find the number of notes of each denomination that the teller can give a customer for a certain amount of money so that they handle a minimum number of notes. Write a program to list out the number of notes of each denomination for an amount received by the user.
Note: Here, the Greedy approach yields an optimal solution as the given bill ...
US dollar