What mistake do I have here?


#1



https://www.codecademy.com/courses/python-beginner-P5YtY/1/3?curriculum_id=4f89dab3d788890003000096#


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: unexpected indent (python, line 14)


It has to return cost


Replace this line with your code. 
def hotel_cost(nights):
    return 140 * nights
def plane_ride_cost(city):
    if city == 'Charlotte':
        return 183
    elif city == 'Tampa':
        return 220
    elif city == 'Pittsburgh':
        return 222
    elif city == 'Los Angeles':
        return 475
    def rental_car_cost(days):
        cost = 40 * days
            if days >= 7:
                cost = days * 40 - 50
            elif days >= 3:
                cost = days * 40 - 20
                    return cost


#2

This function looks like it is in the code block of the function above it. Remove indentation.

Be sure your if, elif and return statement all line up with cost.


#3

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