This article mainly shares with you two python implementations of switching functions, hoping to help everyone.
# After installation, use activate to activate an environment
activate python34 # for Windows
source activate python34 # for Linux & Mac
# After activation, you will find that there are many places for terminal input The word python34 is missing. In fact, what the system does at this time is to remove the default 2.7 environment from the PATH, and then add the commands corresponding to 3.4 to the PATH
# At this time, enter
python again -- version
# You can get `Python 3.4.5 :: Anaconda 4.1.1 (64-bit)`, that is, the system has been switched to the 3.4 environment
# If you want to return to the default python 2.7 environment, run
deactivate python34 # for Windows
source deactivate python34 # for Linux & Mac
# Delete an existing environment
conda remove --name python34 --all
Related recommendations:
Two Python web frameworks: Django & Tornado comparison
The above is the detailed content of Two pythons implement switching function. For more information, please follow other related articles on the PHP Chinese website!