I think all my utility add and take kinda obscure the code a bit. Oh well. Also I'm flipping makeChange because I realized after that foldM applies the arguments in the other order, and I was too lazy to rewrite :P
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Haskell:
I think all my utility
add
andtake
kinda obscure the code a bit. Oh well. Also I'm flippingmakeChange
because I realized after thatfoldM
applies the arguments in the other order, and I was too lazy to rewrite :P