There are three primary types of loop constructs in Swift: while loops, which repeat a block of code as long as a stated condition holds, repeat-while loops which are similar to while loops but are guaranteed to execute the block of code at least one time, and for-in loops, which execute a block of code once for each element in a collection.
For more information, see: