Intro to Flow Control#
Flow control and loops are primary concepts in programming, and support the repetition of code blocks multiple times (for and while loops) and control decisions in your code (if).
The flow control and loops are defined by:
if/elseflow control: these statements allow the execution of a block of code according to True/False conditionsforloop: this statement gives a loop interation over a sequence (e.g., list, string, and tuples), and execute a block of code each time with one element of this iterable objectwhileloop: this statement gives a loop in a block of code until a given condition isFalse
Let’s discuss them!