You are typing in a z shell , but you are trying to execute python code. To enter python's interactive mode, you can simply type /usr/bin/local/python3
(or python3
directly might work if things are setup correctly on your computer). Once you do that, you should see something like
Python 3.9.2 (default, Jul 16 2021, 11:47:35)
[Clang 12.0.5 (clang-1205.0.22.11)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>>
in which you can type your lines of python code
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.