Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 7850a59

Browse files
committed
2 parents c02e03a + 3a2dd6b commit 7850a59

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

ExceptionalHandling/EHFinally.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,16 @@
2323
finally:
2424
# this block is always executed
2525
# regardless of exception generation.
26-
print('This is always executed')
26+
print('This is always executed')
27+
for num in list(range(0,10)):
28+
if num%2 ==0:
29+
continue
30+
print(num)
31+
32+
# have you heard about break/continue
33+
34+
# by default continue will not support inside finally
35+
# from 3.8.3, continue is supported inside finally
2736

2837

2938

0 commit comments

Comments
 (0)