I am not sure why we need finally
in try...except...finally
statements. In my opinion, this code block
try:
run_code1()
except TypeError:
run_code2()
other_code()
is the same with this one using finally
:
try:
run_code1()
except TypeError:
run_code2()
finally:
other_code()
Am I missing something?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…