Artifact fd2e55f7de8062669675dc43457661190d8528aa4f8908648dd615ba78621677:
- Executable file
r37/lisp/csl/html/r37_0048.html
— part of check-in
[f2fda60abd]
at
2011-09-02 18:13:33
on branch master
— Some historical releases purely for archival purposes
git-svn-id: https://svn.code.sf.net/p/reduce-algebra/code/trunk/historical@1375 2bfe0521-f11c-4a00-b80e-6202646ff360 (user: arthurcnorman@users.sourceforge.net, size: 799) [annotate] [blame] [check-ins using] [more...]
<A NAME=FOREACH> <TITLE>FOREACH</TITLE></A> <b><a href=r37_idx.html>INDEX</a></b><p><p> <B>FOREACH</B> _ _ _ _ _ _ _ _ _ _ _ _ <B>command</B><P> <P> <P> <P> <em>foreach</em>is a synonym for the <em>for each</em> variant of the <A HREF=r37_0047.html>for</A> construct. It is designed to iterate down a list, and an error will occur if a list is not used. The use of <em>for each</em> is preferred to <em>foreach</em>. <P> <P> <P> <H3> syntax: </H3> <em>foreach</em><variable> in <list> <action> <expression > <P> <P> where <action> ::= <em>do | product | sum | collect | join</em> <P> <P> <P> <P> <H3> examples: </H3> <P><PRE><TT> foreach x in {q,r,s} sum x**2; 2 2 2 Q + R + S </TT></PRE><P>