Lists

### 3.2.3 Lists

A list is delimited by [ and ], its elements must be separated by commas. For example, [1,2,5] is a list of three integers. Lists are also called vectors in Xcas.

Lists can contain lists (for example, a matrix is a list of lists of the same size, see Section 13.2). Lists may be used to represent vectors (lists of coordinates), matrices, or univariate polynomials (lists of coefficients by decreasing order, see Section 10.1.1).

Lists are different from sequences, because sequences are flat: an element of a sequence cannot be a sequence. Lists are different from sets, because for a list, the order is important and the same element can be repeated in a list (unlike in a set where each element is unique). See Section 5.3 for operations on lists.

In Xcas output:

- matrix and list delimiters are displayed as square brackets ([ and ]),
- polynomial delimiters are displayed as ▯, ▯
- set delimiters are displayed as ⟦, ⟧.