def greedy_give_change(denominations, amount):
    denominations = sorted(denominations, reverse=True)
change_given = list()
for d in denominations:
    while amount > d:
        change_given.append(d)
amount -= d
return change_given
australian_coins = [100, 50, 20, 10, 5, 2, 1, 0.5, 0.2, 0.1, 0.05]
change = greedy_give_change(australian_coins, 313.37)
print(change)
print(sum(change))
Finding shortest combinations in array/sequence that equals sum