File r37/lisp/csl/html/r37_0137.html artifact cd9aaae022 part of check-in a57e59ec0d



<A NAME=APPEND>

<TITLE>APPEND</TITLE></A>
<b><a href=r37_idx.html>INDEX</a></b><p><p>



<B>APPEND</B> _ _ _  _ _ _  _ _ _  _ _ _ <B>operator</B><P>
<P>
 
 <P>
<P>
The <em>append</em> operator constructs a new 
<A HREF=r37_0053.html>list</A> 
from the elements of its two arguments (which must be lists). 
<P>
<P>
 <P> <H3> 
syntax: </H3>
<em>append</em>(&lt;list&gt;,&lt;list&gt;) 
<P>
<P>
<P>
&lt;list&gt; must be a list, though it may be the empty list (<em>{}</em>). 
Any arguments beyond the first two are ignored. 
<P>
<P>
 <P> <H3> 
examples: </H3>
<P><PRE><TT>
alist := {1,2,{a,b}}; 

  ALIST := {1,2,{A,B}} 


blist := {3,4,5,sin(y)}; 

  BLIST := {3,4,5,SIN(Y)} 


append(alist,blist); 

  {1,2,{A,B},3,4,5,SIN(Y)} 


append(alist,{}); 

  {1,2,{A,B}} 


append(list z,blist); 

  {Z,3,4,5,SIN(Y)}

</TT></PRE><P>The new list consists of the elements of the second list appended 
to the 
elements of the first list. You can <em>append</em> new elements to the 
beginning or end of an existing list by putting the new element in a 
list (use curly braces or the operator <em>list</em>). This is 
particularly helpful in an iterative loop. 
<P>
<P>
<P>


REDUCE Historical
REDUCE Sourceforge Project | Historical SVN Repository | GitHub Mirror | SourceHut Mirror | NotABug Mirror | Chisel Mirror | Chisel RSS ]