具有多个 python 解释器的环境

environment with multiple python interpreter

在Mac上,如果安装了多个Python解释器(anaconda,Python2.7标准等),想知道什么时候运行ning命令python , 有没有办法指定我 运行 使用 anaconda 还是 Python 2.7 或其他 Python 解释器?

如果您只输入 python,它将带您到 python 指定的版本:

which python

此命令将在您的终端中打印出 python 的位置。

要使用上述版本以外的版本,无论是 Jython 还是 Anaconda 或其他版本,您可以通过输入完全限定路径来 运行 它。