Need a vacation from taking a vacation

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

This is giving me a SyntaxError on the line with “Tampa” I paste the solution in and it works fine but if I type it out it gives me the error. Is this wrong somehow because I see no difference between this and the solution. I would like to just move on from this but I would like to know what I am doing wrong first.

Thanks in advance.


If you notice, the code block inside the function is not indented as required. Be sure you use spaces, and not tabs.


That was it. Thank you for your time I appreciate it.


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