0

What is diference between finally and except

try catch

28th Feb 2017, 10:33 PM
Hugo Martínez
Hugo Martínez - avatar
2 Réponses
0
Normally : you get into the Try and if there aren't any except, you will finish to do Try and you get into Finally. Except case: you get into the Try, find some errors ( TypeError, etc ), you get the Except,Except is executed, then get into Finally that will be executed. Finally is always executed, no matter if an error is raised or not.
28th Feb 2017, 11:41 PM
Andrei C. Roman
Andrei C. Roman - avatar
0
Finally: Always exec Except: One or more exeptions is "cath" on block and manage the exeption to prevent the program explode or crash.
1st Mar 2017, 1:25 AM
nextco
nextco - avatar