HI, I am trying to read a file in my code named numbers.txt, but when I run it to open the file, the code it says
Errno 2 no such file or directory: ‘numbers.txt’
why would that happen?
I saved the file in windows notepad.
Here is my code:
def main(): infile = open('numbers.txt', 'r') file_contents = infile.read() infile.close() print(file_contents) main()