I'm currently doing an assignment that requires me to use CSV files in Python. I have the .csv file in the same directory as the program itself, yet it gives me the same "No such file or directory" error.
I am sure the name is not a problem. This problem has happened to me before with another file and I wasn't able to fix that either.
Code:
with open('file.csv') as file:
content = csv.reader(file, delimiter=',')
FileNotFoundError: [Errno 2] No such file or directory: 'file.csv'