Nearby lessons
43 of 108Python - Looping Statements
Introduction
Flow Control decides the order in which Python statements are executed.
It helps the program make decisions, repeat tasks, and control the execution of statements.
Types of Flow Control Statements
Python provides three types of flow control statements.
| Category | Statements |
|---|---|
| Conditional Statements | if, if-elif, if-elif-else |
| Iterative Statements | while, for |
| Transfer Statements | break, continue, pass |
Iterative Statements
Sometimes we need to execute a group of statements multiple times.
This repeated execution is called Iteration.
Python provides two iterative statements:
whileLoopforLoop
Flow Control Summary
| Category | Statements |
|---|---|
| Conditional Statements | if, if-elif, if-elif-else |
| Iterative Statements | while, for |
| Transfer Statements | break, continue, pass |
Quick Revision
| Statement | Main Purpose |
|---|---|
if |
Decision Making |
while |
Repeat until condition becomes False |
for |
Iterate through a sequence |
break |
Exit the loop |
continue |
Skip current iteration |
pass |
Placeholder statement |
🧠 Test Your Knowledge
40 QuestionsProgress: 0 / 40
Keep Going!Python - For Loop with String