Hi, can someone try to helping with this code? If the syntax is wrong or anything else? right now I have problems with Indentation. Please can you post me an answer with the tool "preformatted text"? It's very important. Thanks
error message: File "python", line 25 print total ^ IndentationError: unexpected indent
but I don't know if there are others.
def rental_car_cost(days): total = 40*days if days>=7 : total= total - 50 print total return total elif days>=3 : total = total -20 print total return total
I have tried also this:
def rentalCarCost(days): rentalCost = days * 40 if days >= 3 and days < 7: return rentalCost - 20 elif days >= 7: return rentalCost - 50 else: return rentalCost print rentalCarCost(10)
with this error:
Oops, try again. It looks like rental_car_cost returns None instead of the correct amount (40) for 1 days.
can someone help me?