The operator [i] returns the ith element of a list, and the operator [i:j] returns the sublist starting at element i and ending at element j. If j is omitted, the entire sublist starting with element i is returned.
Prototype
list <-- list [ number [ : [ number ]] ]
Examples
%To <ABBR>Mr</ABBR> Jones%[2]; <ABBR> Mr </ABBR>(top DATE within file $myfile)[2]; <DATE> 8 September 1992 </DATE>(top DATE within file $myfile)[2:3]; <DATE> 8 September 1992 </DATE><DATE> May 1988 </DATE>(top DATE within file $myfile)[3:]; <DATE> May 1988 </DATE><DATE> 6 and 7 May 1991 </DATE><DATE> 14 November 1991 </DATE><DATE> 16 June 1959 </DATE><DATE> 26 October 1992 </DATE><DATE> 18 March 1980 </DATE><DATE> 16 June 1959 </DATE><DATE> 28 January 1992 </DATE><DATE> 4 September 1992 </DATE>