Getting There


#1

def hotel_cost(nights):
    return 140 * nights
    #140$ per night
def plane_ride_cost(city):
    if city == "Charlotte":
        return 183
    elif city == "Tampa":
        return 220
    elif ciry == "Pittsburgh":
        return 222
    elif city == "Los Angeles":
        return 475
    else:
        return None

Oops, try again. Did you create a function called plane_ride_cost?

What should I do?


#2

Hello

Delete the else statement at the end. You need to return with something not None.


#3

Thank u but it was for ciry in line 9


#4

Nicely spotted. I did my end differently to you. Well done you fixed it yourself.


#5

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