Need help getting past this


#1

def hotel_cost(nights):
return 140*nights

def plane_ride_cost(city):
if city == "Charlotte":
return 183
elif city == "Tampa":
return 220
elif city == "Pittsburg":
return 222
elif city == "Los Angeles":
return 475
else:
return plane_ride_cost

def rental_car_cost(days):
costs = days * 40
if days >= 7:
return costs - 50
elif days >= 3:
return costs -20
else:
return costs

def trip_cost(city, days):
total= rental_car_cost(days) + hotel_cost(days) + plane_ride_cost(city)
return total

Oops, try again. plane_ride_cost('Pittsburgh') returned instead of the correct value 222

i need help getting past this/


Taking a Vacation - Putting it together
#2

Check your spelling against the error message.


#4

2 posts were split to a new topic: Unsupported operand type(s) for -: 'str' and 'int'


#5

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.