Professional Documents
Culture Documents
Control
MR. MICHAEL ANGELO I. DUNGO
INSTRUCTOR I
If..elif..else
If some_condition_is_true:
Execute this code
elif some_other_condition_is_true:
Execute this code
else:
Execute this code
For loop
iterable_object = [1,2,5,9]
for item in iterable_object:
print(item)
Range
The continue statement can be used in both while and for loops.
Break
While loop will continue to execute a block ofcode while some test
condition remains True
while some_Boolean_condition_is_true:
do something(while block of code)
else:
another block of code
While and Continue
While and Break