Challenge: Money Change

Solve the Money Change Problem using a greedy approach.

We'll cover the following

Problem


Money Change Problem

Compute the minimum number of coins needed to change the given value into coins with denominations 11, 55, and 1010.

Input: An integer moneymoney.
Output: The minimum number of coins with denominations 11, 55, and 1010 that change moneymoney.


Level up your interview prep. Join Educative to access 80+ hands-on prep courses.