ABSTRACT

In order to be able to do something useful, programs must have some mechanism to manage how and when instructions are executed. In the same way that traffic lights control vehicular flow in a street, flow control structures direct that code portion is executed at a given time. For greater simplicity, Python has only three flow control structures. There

is one conditional and two iteration structures. A conditional structure (if) determines, after an expression evaluation, whether a block of code is executed or not. Iterative structures allow multiple execution of the same code portion. How many times is the code associated to a iterative structure executed? It depends the kind of cycle. A for cycle executes a code block many times as elements on are available in a specified iterable element, while the code under a while cycle is executed until a given condition turns false.1