append

Gamma: Version 4.0
Prev |  | Next

# `append`

`append` -- concatenates several lists into a single new list.

## Syntax

    append (list...)

## Arguments

`list`

  One or more lists.

## Returns

A new list whose elements are the all of the elements in the given lists, in the order that they appear in the argument lists.

## Description

This function concatenates all of the argument lists into a single new list, in the order the arguments are given. Each list is appended to the preceding list by assigning it to the cdr of the last element of that list. The appending is non-destructive; for a destructive version of append use `nappend`.

## Example

        Gamma> append (list(1,2,3), list(4,5));
        (1 2 3 4 5)
        Gamma> append (list(#a,#c,#g), list(#b,#d,#z));
        (a c g b d z)
        Gamma>

## See Also

`nappend`

Prev | Home | Next
Lists and Arrays | Up | `aref`

Copyright 1995-2002 by Cogent Real-Time Systems, Inc.