try:
x=100/0
except Exception as e:
print('error:', e)
else:
print('x =', x)
finally:
print('over!')
try:
x=100/0
except Exception as e:
print('error:', e)
else:
print('x =', x)
finally:
print('over!')
本文标题:try完整语法示例
本文链接:https://www.haomeiwen.com/subject/bcubgdtx.html
网友评论