Repeat-While Loops in Swift

The repeat-while loops evaluates the test condition after executing the set of instructions once to decide whether to iterate  through the loop again.

Syntax:

repeat {

} while <condition>

Example:

Leave a Reply