In programming, Control Flow refers to how the order of instructions (statements) are executed. Swift provides the standard set of conditional constructs. These include for, repeat, while, if, do, guard, and switch, plus break and continue to transfer the control to another location in the code.
Even though these constructs are familiar, they provide considerably powerful support for safety.
A for loop construct provides a way for a block of code to be executed a number of times. Swift provides two types of for loops.