Hi there, i'm learning python by reading a book and i am stuck in one of its examples:

i created succesfully a file with a basic script in it (i run it with the GUI) and it works fine, the file is named script1.py and i saved it in C:\Users\username\doocuments\varios 2\python journey\

the book says this:

Once you’ve saved this text file, you can ask Python to run it by listing its full filename
as the first argument to a python command, typed at the system shell prompt:
% python script1.py

Remember to replace “python” with a full directory path, as before, if your
PATH setting is not configured.

Sooo, my question is what is the full directory path that one must enter? in order to make it work?

6 Years
Discussion Span
Last Post by askandstudy

If PATH environment variable include your Python install directory,you can run:

cd C:\Users\username\doocuments\"varios 2"\"python journey"
python script1.py

or like this:

c:\python26\python script1.py

In dos command window run "set PATH",can show PATH variable.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.