### while

#### while [reporter] [ commands ]

If reporter reports false, exit the loop. Otherwise run commands and repeat.

The reporter may have different values for different agents, so some agents may run commands a different number of times than other agents.

    while [any? other turtles-here]
      [ fd 1 ]
    ;; turtle moves until it finds a patch that has
    ;; no other turtles on it

Take me to the full NetLogo Dictionary