Reputation: 110562
I have always used a mac to write and run python scripts. However, I have a bunch of files on a PC that I need to run a script on. I have never really used a PC and don't know how to run the script.
If I go to the command
program on the PC and type in python
, nothing happens. How do I find where the python path is in order to get into the python prompt
? Also, once I am in the prompt, is the importing of modules
the same as in a Unix
system?
Upvotes: 0
Views: 2890
Reputation: 6352
Python isn't added to the system environment's PATH variable by default on windows. You have to either add the path to the directory containing the Python.exe file to the PATH variable, or call python explicitly.
This issue has been addressed in the Python documentation: Python Documentation: # How to run a Python program under windows
Upvotes: 3
Reputation: 1245
Assuming Python is installed, it is usually placed in a folder prefixed with "Python" and the major/minor version. E.g. C:\Python26
Upvotes: 1