I wish to apply conditions to a moving element in my swift program but not able to do it. The elements are moving indefinitely without any boundaries.
>Solution :
Below is the link to get complete information about the swift data types, particularly control flow.
https://docs.swift.org/swift-book/LanguageGuide/ControlFlow.html