+ 2

Can someone please correct me

My attempt- paint = float(input()) paint_cost = paint*5.0 tax = ((40.0+paint_cost)*1/10) total_cost = tax + 40.0 + paint_cost print(int(total_cost)) Question- You are getting ready to paint a piece of art. The canvas and brushes that you want to use will cost 40.00. Each color of paint that you buy is an additional 5.00. Determine how much money you will need based on the number of colors that you want to buy if tax at this store is 10%. Task Given the total number of colors of paint that you need, calculate and output the total cost of your project rounded up to the nearest whole number. Input Format An integer that represents the number of colors that you want to purchase for your project. Output Format A number that represents the cost of your purchase rounded up to the nearest whole number. Sample Input 10 Sample Output 99

25th Jul 2020, 3:46 PM
Amit Kumar
Amit Kumar - avatar
7 ответов
+ 9
It says to round up(Math.ceil(total_cost) but you are converting result to int
25th Jul 2020, 3:50 PM
Abhay
Abhay - avatar
+ 11
As written in the task description, the total cost has to be rounded up to the nearest whole number. I think this missing in your code.
25th Jul 2020, 3:51 PM
Lothar
Lothar - avatar
+ 4
Amit Kumar Don't write too much just Click on the share Icon on the top right of of Code Coach task page. https://www.sololearn.com/coach/22?ref=app And please don't write Code in question.Click on three dots and click edit question and then on the plus icon and then Click on Insert Code to insert Your Code
25th Jul 2020, 3:55 PM
Akash Sharma
Akash Sharma - avatar
+ 3
Ohh I didn't knew that Btw thank you
25th Jul 2020, 3:51 PM
Amit Kumar
Amit Kumar - avatar
+ 1
Amit Kumar You're Welcome.
25th Jul 2020, 3:57 PM
Akash Sharma
Akash Sharma - avatar
+ 1
Use this: import math math.ceil In calculating tax.
25th Jul 2020, 8:13 PM
Busyj
+ 1
Bonjour ava de le faire en
26th Jul 2020, 8:38 PM
Jordan Silvestre
Jordan Silvestre - avatar