gpt4 book ai didi

python - 在 Mac OS X 上运行 "python"和 "python2.7"有什么区别?

转载 作者:太空宇宙 更新时间:2023-11-03 13:19:50 25 4
gpt4 key购买 nike

当我从 Mac 上的终端运行 python 时,我得到以下前两行:

Python 2.7.5 (v2.7.5:ab05e7dd2788, May 13 2013, 13:18:45)
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin

当我运行 python2.7 时,我得到了这个:

Python 2.7.5 (default, May 19 2013, 13:26:46)
[GCC 4.2.1 Compatible Apple Clang 4.1 ((tags/Apple/clang-421.11.66))] on darwin

我可以识别 python2.7 中的 scipynumpy,但不能识别普通的 python。

它们之间到底有什么区别?有什么办法可以让 python import scipy 吗?我可以只将 python2.7 别名为 python 而忘记这个吗?

最佳答案

这是两个不同的 python

尝试whereis pythonwhereis python2.7获取它们的具体位置。

关于python - 在 Mac OS X 上运行 "python"和 "python2.7"有什么区别?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18069753/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com