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 python
to bring up an interactive session, and as I hoped, it brought up python 3.3.
I am also aware of the shorter py
command. However when I try py
in command prompt, it brings up python 2.7. I can use py -3
to bring up 3.3, but that makes it longer than it needs to be, and seeing as I will be dealing primarily with version 3.3, I would like py
and python
to both bring up a Python 3.3 interactive session.
I am somewhat familiar with Window's PATH system, but I can't see why this is happening. How can I set it up so that both py
and python
, when typed into a windows command prompt, will start a Python 3.3 interactive session unless otherwise specified, e.g. via something like py -2
?
Thanks.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…