【macOS】【zsh Error】zsh: command not found: python
本地已经安装了Python,且能在Pycharm中编译Python程序并运行。
但是,在macOS终端,运行Python,报错。
首先要确认你在macOS系统下,是否安装了Python。
如果安装了,还要确认Python名称。
例如,我在终端输入python,报错:zsh: command not found: python。
而实际上,我的Python,安装在路径:/usr/local/bin
且文件名为:Python3.
所以,需要在终端输入:python3,才能正确运行。

----------------------------------------
下面是配置环境变量的步骤:
----------------------------------------
There are a few possible reasons why you might be getting this error:
1. Python is not in your PATH:
-
Check the installation location:
Make sure you installed Python to a directory that is in your system's PATH.
Common locations include/usr/local/binor/opt/anaconda

最低0.47元/天 解锁文章
1914

被折叠的 条评论
为什么被折叠?



