I want to run a python file in my command prompt but it does nothing.
These are the screen shots of my program i am testing with and the output the command prompt gives me.
Asked
Active
Viewed 1.7e+01k times
2

Abdullah Bilal
- 393
- 1
- 6
- 12
-
Here is google search link - https://www.google.co.in/webhp?sourceid=chrome-instant&ion=1&espv=2&ie=UTF-8#q=how%20to%20install%20and%20configure%20python%20on%20windows – Dinesh Pundkar Sep 13 '16 at 05:33
-
2Please don't post text as images... – Dan Cornilescu Sep 13 '16 at 05:40
3 Answers
20
First set path of python
https://stackoverflow.com/questions/3701646/how-to-add-to-the-pythonpath-in-windows
and run python
file
python filename.py
command line argument with python
python filename.py command-line argument
2
First go to the directory where your python script is present by using-
cd path/to/directory
then simply do:
python file_name.py

V.Khakhil
- 285
- 5
- 22