chandan sharma
chandan sharma

Reputation: 1

Unable to Execute .py file

Even though I have python installed in my system. I'm unable to execute .py file. below is the error. Please assist.

C:\Users\chandan\Desktop>py first.py C:\Users\chandan\AppData\Local\Programs\Python\Python37-32\python.exe: can't open file 'first.py': [Errno 2] No such file or directory.

Upvotes: 0

Views: 171

Answers (1)

AmilaMGunawardana
AmilaMGunawardana

Reputation: 1830

the file name should not contain any spaces. if you are using spaces use "" eg python "py first.py"

Upvotes: 1

Related Questions