Mathematica 9 is now available
 Documentation / Mathematica / Built-in Functions / Programming / Flow Control  /
Goto

  • Goto[ tag ] scans for Label[ tag ], and transfers control to that point.
  • Goto first scans any compound expression in which it appears directly, then scans compound expressions which enclose this one.
  • See the Mathematica book: Section 2.5.9Section 2.5.9.
  • See also: Throw, Switch, Which.

    Further Examples

    This goes on looping until q exceeds 6.

    In[1]:=

    2

    3

    4

    5

    In[2]:=



    Any questions about topics on this page? Click here to get an individual response.Buy NowMore Information
    THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
    SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.