next up previous contents index
Next: goto, label Up: Control Structures Previous: break   Contents   Index

continue

continue [ n]

In a loop, continue causes the loop to be reentered from the top. If an integer n is given, the n'th enclosing loop is reentered.

Example:
while x <= 100
  # continue will jump here
  while y <= 50
    while z <= 20
       statements
       if (x + y + z == 10)
           continue 2
       end
    end
  end
end



Stephen R. Whiteley 2024-09-29