python 退出程序的执行

使用sys.exit()退出当前程序的执行

import sys

if x==0:
   sys.exit()
原文地址:https://www.cnblogs.com/imhuanxi/p/11069471.html