The Boredless Tourist: code runs on my terminal but won't run on Codecademy bash


I am working on this project, and when I execute this code it gives me error message. But the exact same code would run on my terminal. I have definitely saved my changes, added files and committed them. Can anyone help me understand where I am doing wrong?

Compare what’s in the CC terminal w/what’s on your machine.


destination = destinations.index(destination)
    return destination_index


destination_index = destinations.index(destination)
    return destination_index

What’s different with that variable definition?


I swear it was copied and pasted :rofl:, if the code worked I wouldn’t have tried it on my terminal.

Thank you very much lisalisaj, for spotting it! Now I can move on with the project :smiley:

1 Like