In[1]:
path='/Users/apple/Downloads/train.csv'
open(path).readline()
Out[1]:
FileNotFoundError Traceback (most recent call
last)
<ipython-input-7-7fad5faebc9b> in <module>()
----> 1 open(path).readline()
FileNotFoundError: [Errno 2] No such file or directory:
'/Users/apple/Downloads/train.csv'
I'm confused a lot.I thought this code is exactly similar with many tutorials, and I'm sure I have this file in the right path, but why does it not works?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…