Cashback

Cashback on payment methods (e.g. credit card) is a common term nowadays. That is, if you pay using …

Click here to read the complete problem statement.


If you need help solving this problem, mention your approach and ask specific questions. Please avoid sharing your code and asking the Community to figure out “what’s wrong”.

I iterated through all the scenario using the concept of set and dynamic programming. I rechecked my codes several times, still couldn’t find any issue, unless it is a floating-point issue (that I’m not sure about). Please help me fix my code. :pleading_face:
My code: cashback on Github