We all love a little bargain.
Your function will get a price, and a load of discounts. Your job is to write the function so that it calculates the maximum possible discount.
15%, 8, 50%.%, and amounts, without %.discount(64, "50%, 50%") ➞ 16
# Reduce 50% twice.
discount(24, "20, 2") ➞ 2
# Subtract 20 and 2.
discount(20, "10, 10%") ➞ 8
# Apply 10% discount first and then subtract 10.
N/A