tests: Add another test for break-from-for-loop.

pull/651/head
Damien George 2014-05-31 16:56:15 +01:00
rodzic ff8da0b835
commit 049a01d148
1 zmienionych plików z 12 dodań i 0 usunięć

Wyświetl plik

@ -13,3 +13,15 @@ def foo():
i -= 1
foo()
# break from within nested for loop
def bar():
l = [1, 2, 3]
for e1 in l:
print(e1)
for e2 in l:
print(e1, e2)
if e2 == 2:
break
bar()