Walmart Global Tech interview question

Coin change problem pseudo code