Here's the question you clicked on:

55 members online
  • 0 replying
  • 0 viewing

ReindeerGames

  • 2 years ago

In problem set 2 hangman, my program was running perfectly last time I checked. I opened it to mess with it some more and now it's telling me "IOError: [Errno 2] No such file or directory: 'words.txt'" which I think means it's not finding the file to get the words out of. It was doing it before but it's not now. Any ideas?

  • This Question is Open
  1. 6.00_learner
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 0

    After ascertained that 'words.txt' is in the same directory with your python code. restart the python idle might be a choose :)

  2. e.mccormick
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 0

    Yah, make sure something did not get deleted, then look at where you are starting the program from. Sometimes a path call can be different if you right click and run vs. open python then open file.

  3. Richard_C
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 0

    Agree with the above comment. Make sure that 'words.txt' is in the same directory as the .py file.

  4. ReindeerGames
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 0

    Thanks! I had saved it a different place on accident. :)

  5. e.mccormick
    • 2 years ago
    Best Response
    You've already chosen the best response.
    Medals 0

    That would do it! Have fun.

  6. Not the answer you are looking for?
    Search for more explanations.

    • Attachments:

Ask your own question

Sign Up
Find more explanations on OpenStudy
Privacy Policy