+ 1

Paint Cost

I keep failing test 3 and I don’t know why. Can anyone help? supplies = 40.00 paint = int(input())*5 tax = (supplies + paint)*0.1 total = (supplies + paint) + tax print(int(round(total)))

13th Mar 2020, 6:33 AM
Alan
Alan - avatar
4 Antworten
+ 8
Use ceil() istead of round() Here is the fixed code👇 https://code.sololearn.com/clYu8S2D4J6f/?ref=app
13th Mar 2020, 6:39 AM
Arsenic
Arsenic - avatar
+ 3
This is because paint box are individual units. If you need 2.3 paint , you have no option but to but 3 paint boxes.
13th Mar 2020, 6:44 AM
Arsenic
Arsenic - avatar
+ 1
Thank you so much!
13th Mar 2020, 6:46 AM
Alan
Alan - avatar
0
What actually test 3 might be, it must be integral right?
18th Dec 2021, 7:46 PM
Bagus Tri Handoko
Bagus Tri Handoko - avatar