Sophie

Sophie

distrib > Mandriva > 2010.0 > i586 > media > contrib-release > by-pkgid > bd5c3d824c3db63ffd9226c15941e6ad > files > 1982

mozart-1.4.0-1mdv2010.0.i586.rpm

<HTML><HEAD><TITLE>Tcl Built-In Commands - lrange manual page</TITLE></HEAD><BODY>
<H3><A NAME="M2">NAME</A></H3>
lrange - Return one or more adjacent elements from a list
<H3><A NAME="M3">SYNOPSIS</A></H3>
<B>lrange </B><I>list first last</I><BR>
<H3><A NAME="M4">DESCRIPTION</A></H3>
<I>List</I> must be a valid Tcl list.  This command will
return a new list consisting of elements
<I>first</I> through <I>last</I>, inclusive.
<I>First</I> or <I>last</I>
may be <B>end</B> (or any abbreviation of it) to refer to the last
element of the list.
If <I>first</I> is less than zero, it is treated as if it were zero.
If <I>last</I> is greater than or equal to the number of elements
in the list, then it is treated as if it were <B>end</B>.
If <I>first</I> is greater than <I>last</I> then an empty string
is returned.
Note: ``<B>lrange </B><I>list first first</I>'' does not always produce the
same result as ``<B>lindex </B><I>list first</I>'' (although it often does
for simple fields that aren't enclosed in braces); it does, however,
produce exactly the same results as ``<B>list [lindex </B><I>list first</I><B>]</B>''

<H3><A NAME="M5">KEYWORDS</A></H3>
<A href="../Keywords/E.htm#element">element</A>, <A href="../Keywords/L.htm#list">list</A>, <A href="../Keywords/R.htm#range">range</A>, <A href="../Keywords/S.htm#sublist">sublist</A>
<HR><PRE>
<A HREF="../copyright.htm">Copyright</A> &#169; 1993 The Regents of the University of California.
<A HREF="../copyright.htm">Copyright</A> &#169; 1994-1996 Sun Microsystems, Inc.
<A HREF="../copyright.htm">Copyright</A> &#169; 1995-1997 Roger E. Critchlow Jr.</PRE>
</BODY></HTML>