Given several Python classes/objects with failing tests, find which functions' tests fail, explain why, and fix them; then modify one function and write a new function.
Asked in the Round not visible stage. One sub-question modifies an existing function, and the other adds a new function. Implement the corrected classes and run_tests(cases), which returns the names of failing tests.
Rewards.points(amount) returns two points per complete $10, plus 10 bonus points when amount >= 100. Card.mask(number) masks every digit except the final four. Card.redeem(balance, cost) returns the remaining balance, or -1 when funds are insufficient.
name, function, args, and expected keysRewards.points, Card.mask, or Card.redeemdef run_tests(cases):