S.M Rifat Ibn Musa
S.M Rifat Ibn Musa

Reputation: 1

How can I run Python program on cmd?

I've tried to run code on the cmd but it isn't working. I'm using windows7 and I changed the path from the default but I wrote the directory on the cmd. Can anyone help me?

Upvotes: 0

Views: 43

Answers (2)

rui.zhang
rui.zhang

Reputation: 29

make sure python in your system path; set python root path to system environment variable;then you can run 'python filename.py' ex

Upvotes: 0

Anoop K George
Anoop K George

Reputation: 1735

python3 yourfilename.py

The above command can run your code, makesure you are at the project directory.

Upvotes: 1

Related Questions