sort -- sort a list |
Syntax |
sort(ref L: LIST) |
Description |
Example |
/**/ L := [3,2,1]; /**/ sort(ref L); -- this returns nothing and modifies L /**/ L; [1, 2, 3] /**/ use R ::= QQ[x,y,z]; /**/ L := [x,y,z]; /**/ sort(ref L); -- this returns nothing and modifies L /**/ L[1]; z /**/ sorted([y, x, x^2]); -- this returns the sorted list [y, x, x^2] |
See Also |