I've tried every way and still comes out incorrect so I really dont kow what i'm doing wrong. I see other posts where people did the same exact things I did and it worked for them. Really need some help cause I'm on a deadline to learn this language. Thanks in advace.
Oops, try again. It looks like rental_car_cost returns None instead of the correct amount (40) for 1 days.
and with the -=50 and -=20 i get:
Oops, try again. Your code looks a bit off. Feel free to peek back at earlier exercises if you need a refresher! Your code threw the following error: can't assign to operator (python, line 19) (python, line 17)
when i take out else before return at the bottom i get:
Oops, try again. It looks like rental_car_cost returns 120 instead of the correct amount (100) for 3 days.
def rental_car_cost(days): cost = 40 if days >= 7: days * cost - 50 elif days >= 3 or days < 7: days * cost - 20 else: return days * cost