clojure-hackos.halloween-sale
Solution to the Halloween Sale challenge. See: https://www.hackerrank.com/challenges/halloween-sale/problem
how-many-games
(how-many-games p d m s)
Returns the number of games that can be purchased with budget s
, given the starting price p
and applying discount d
for each purchased game up to the minimum price m
.