Continue

3.2.5 Continue

DESCRIPTION

Continue - skip the current innermost for loop iteration. If the command is used outside of a for loop it reports a syntax error. Supported since 4.1.3.

To break (exit) the whole for loop use the break command.

SYNOPSIS

continue

RETURNS

The command doesn't modify the exit code and leaves its value on the one returned by the previously executed command.

EXAMPLES

# Increment X for each even loop (the resulting SUM will be 5)
Var SUM=0
for
 (i=0; i<10; i={i}+1) {

   if ({i} % 2 == 1) {
      continue
   }
 
   Eval SUM={SUM}+1 
}