Brand new Python, just getting things set up and installed before I start messing around with things. My understanding is that there are some notable differences/incompatibilities between Python 2.7 and Python 3.3, though both versions are well used, so I thought it best to install both (In their own install directories).
When installing, I used the new 3.3 feature where the installer set the PATH variables for me, however this option is not present for 2.7. After installing both versions, I tried a quick test, opened command prompt, and typed
py is the Windows Python launcher, and it can start any Python version.
On most systems
py is configured to launch Python 2.7 by default if present (this is the default except for Python 3.6 and newer, where Python 3 will be run instead). You have two options if you want to change that:
Set an environment variable;
PY_PYTHON=3 will make
py run the latest Python 3 interpreter instead.
Create a file
py.ini in your application directory with the contents:
This has the same effect as the
PY_PYTHON environment variable. Typically, your application directory is found in
C:\Documents and Settings\[username]\Application Data or
C:\Users\[username]\AppData\Local\py.ini, depending on the Windows version.
You can also add a
#! shebang line to your scripts (first line) to tell the launcher to use Python 3 when you doubleclick such a file: