在不同的pyhon版本中切换

时间:2022-01-24 11:29:56

issue discription

在一台电脑上同时安装了python2.7和python3.5,怎样在这两个版本中切换调用?

solution to the issue

  1. 进入python安装文件夹,将 python.exe 文件分别改名为 python27.exepython35.exe

  2. 在终端(我用的是powershell)调用时用下述命令:

    python27 filename

    python35 filename

    即可在两种中版本中进行切换

相关文章