Vanguard Software
Forecasting & Planning Solutions
Home Products Solutions Services Customers Partners Company
 
Applying science to business management

contents.gifindex.gifprev1.gifnext1.gif

return

The return statement is used to terminate execution of a node definition and optionally return a value. This statement has the format

return expression ;

For example, the following definition scans all elements in a list and returns the first negative value:

First Negative(list):={
for(var n=0; list[n]!=null; n++)
  if(list[n]<0)
     return list[n];
}

If you don't supply a return value with the return statement, e.g.,

return;

the value null is returned. That is, return; is the same as return null;.

See Also

Optional return

  Demand Planning  |  Financial Forecasting
Forecasting Software  |  Strategic Planning Software  |  Decision Tree Software
Decision Support Software  |  Expert System Software  |  Online Surveys

Contact Us  |  Terms of Use  |  Privacy Policy  |  Site Map
Vanguard Software
© 2011 Vanguard Software Corporation
Print this page   Email this page to a friend