atm-dynamic-programming

Write a function that implements an ATM. There are unlimited quantities of 500€, 200€, 100€, 50€, 25€, 20€, 10€ and 5€ banknotes. The algorithm aims at delivering the lowest quantity of banknotes.

atm(170); // 1 x 200€, 1 x 50€ and 1 x 20€ banknotes
atm(40); // 2 x 20€ banknotes