#异常使用 try: #int('asdasd') raise ValueError("我就返回 任性!") except ValueError as e: print("int",e) except IOError as e: print("IO",e) raise e#抛出异常 给下面的来捕获 except Exception as e: print("全部捕获",e)
python3异常使用
猜你喜欢
转载自blog.csdn.net/w739639550/article/details/76184205
今日推荐
周排行