Top
Back: 4.7.1 list declarations
Forward: 4.7.3 list operations
FastBack: 4. Data types
FastForward: 5. Functions and system variables
Up: 4.7 list
Top: Singular 2-0-4 Manual
Contents: Table of Contents
Index: F. Index
About: About This Document

4.7.2 list expressions

A list expression is:

  1. the empty list list()
  2. an identifier of type list
  3. a function returning list
  4. list expressions combined by the arithmetic operation +
  5. a type cast to list

See Type conversion and casting.


Example:

 
  list l = "hello",1;
  l;
→ [1]:
→    hello
→ [2]:
→    1
  l = list();
  l;
→ empty list
  ring r =0,x,dp;
  factorize((x+1)^2);
→ [1]:
→    _[1]=1
→    _[2]=x+1
→ [2]:
→    1,2
  list(1,2,3);
→ [1]:
→    1
→ [2]:
→    2
→ [3]:
→    3

Top Back: 4.7.1 list declarations Forward: 4.7.3 list operations FastBack: 4. Data types FastForward: 5. Functions and system variables Up: 4.7 list Top: Singular 2-0-4 Manual Contents: Table of Contents Index: F. Index About: About This Document
            User manual for Singular version 2-0-4, October 2002, generated by texi2html.