python怎么退出交互模式
打开命令行,当输入“python”命令时,可以看到如下输出结果:
C:UsersAdministrator>python Python 3.7.3 (v3.7.3:ef4ec6ed12, Mar 25 2019, 22:22:05) [MSC v.1916 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "license" for more information. >>>
此时便进入Python的交互模式
退出交互模式,可以使用exit()语句
C:UsersAdministrator>python Python 3.7.3 (v3.7.3:ef4ec6ed12, Mar 25 2019, 22:22:05) [MSC v.1916 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "license" for more information. >>> exit() C:UsersAdministrator>
如上,交互模式便退出了。Python学习网- 专业的python自学、交流公益平台!
来源:PY学习网:原文地址:https://www.py.cn/article.html