Why does it ask me not to use compute_bill?


#1

Question

Why does it ask me not to use compute_bill?

Answer

If you think you’ve coded your function properly and are receiving an error message along the lines of stock doesn't look quite right! Make sure to not call compute_bill since it changes the stock!, this is because in this step we aren’t using the function after writing it, we’re just writing the function.
Try deleting where you used the function and then Run your code again.
It’s great to want to test your code! However, Codecademy runs tests to check your code that depend on the values being the original values, and running the function in your code in this step changes those values. You’ll be able to use it in the very next step!


FAQ: Learn Python: A Day at the Supermarket - Stocking Out