WLJS LogoWLJS Notebook

Goto

Goto[tag] scans for Label[tag], and transfers control to that point.

Examples

Module[{i = 1},
  Label[start];
  If[i < 5, i++; Goto[start]];
  i
]
Do[If[i == 3, Goto[done]]; Print[i], {i, 5}]; Label[done];

Please visit the official Wolfram Language Reference for more details.

On this page