### Related

##### sort

a = sort([1, 7, 3, 56...

a;

Calculate

l: [2,1,4,3];

o: sort(l);

omin: o[1];

Calculate

##### sort

a :sort([1, 7, 3, 56,...

a;

Calculate

##### sort

xpunt1: 1,ypunt1: 2,x...

xpunt1 : newlist[1][1...

xpunt2 : newlist[2][1...

Calculate

a:[3,1,2];

sort(a);

Calculate

##### sort

sort([1, 7, 3, 56, 1]);

Calculate

a:[2,3,5,1,6,7];

sort(a,"<");

Calculate

l:[1,-1,2,-2];

ls:sort(l);

ls;

Calculate

a:[2,3,5,1,6,7];

sort(a,"<");

b:a;

Calculate

##### sort

a: sort([1, 7, 3, 56,...

Calculate

### sort

Run Example
```(%i1)sort(p:makelist(i*(primep(i)-false)/(true-false),i,3,1000));
(%o1) [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 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 313, 317,
331, 337, 347, 349, 353, 359, 367, 373, 379, 383, 389, 397, 401, 409, 419,
421, 431, 433, 439, 443, 449, 457, 461, 463, 467, 479, 487, 491, 499, 503,
509, 521, 523, 541, 547, 557, 563, 569, 571, 577, 587, 593, 599, 601, 607,
613, 617, 619, 631, 641, 643, 647, 653, 659, 661, 673, 677, 683, 691, 701,
709, 719, 727, 733, 739, 743, 751, 757, 761, 769, 773, 787, 797, 809, 811,
821, 823, 827, 829, 839, 853, 857, 859, 863, 877, 881, 883, 887, 907, 911,
919, 929, 937, 941, 947, 953, 967, 971, 977, 983, 991, 997]
(%i2) ```
Run Example
```load (newton1);
(%o1)         /usr/share/maxima/5.21.1/share/numeric/newton1.mac
(%i2) eq1:sin(x)*cos(3*x);
(%o2)                           sin(x) cos(3 x)
(%i3) eq2:eq1*eq1;
2       2
(%o3)                          sin (x) cos (3 x)
(%i4) plot2d(eq1,[x,-3.2,3.2]);
plotli:makelist (i/4, i, -12, 12);
11    5    9         7    3    5         3    1    1     1  1
(%o5) [- 3, - --, - -, - -, - 2, - -, - -, - -, - 1, - -, - -, - -, 0, -, -,
4     2    4         4    2    4         4    2    4     4  2
3     5  3  7     9  5  11
-, 1, -, -, -, 2, -, -, --, 3]
4     4  2  4     4  2  4
(%i6) map(round,[[1.2],[3.5]]);
(%o6)                    [round([1.2]), round([3.5])]
(%i7) string(2.344555);
(%o7)                              2.344555
(%i8) sols:map(round,flatten(sort(outermap(newton, [eq1], [x], li, [1E-6]))*1000))/1000;
1571    1309    1309    1309  131    1571    1571    1571       131
(%o8) [- ----, - ----, - ----, - ----, ---, - ----, - ----, - ----, 0, - ---,
500     500     500     500   250    1000    1000    1000       250
131  131       131  131  131     1571  1571  1571    131  1309  1309  1309
- ---, ---, 0, - ---, ---, ---, 0, ----, ----, ----, - ---, ----, ----, ----,
250  250       250  250  250     1000  1000  1000    250  500   500   500
1571
----]
500
(%i9) round([4.5,5.6]);
(%o9)                          round([4.5, 5.6])
(%i10) ```
Run Example
```A:makelist(random(n)+1,n,1,10);
(%o1)                   [1, 1, 1, 3, 1, 5, 7, 6, 9, 9]
(%i2) A;
(%o2)                   [1, 1, 1, 3, 1, 5, 7, 6, 9, 9]
(%i3) insertion_sort(u) := block( [n: length(u), x, j], for i from 2 thru n do ( x: u[i], j: i - 1, while j >
= 1 and u[j] >
x do ( u[j + 1]: u[j], j: j - 1 ), u[j + 1]: x ));
(%o3) insertion_sort(u) := block([n : length(u), x, j],
for i from 2 thru n do (x : u , j : i - 1,
i
while (j >= 1) and (u  > x) do (u      : u , j : j - 1), u      : x))
j           j + 1    j               j + 1
(%i4) insertion_sort(A);
(%o4)                                done
(%i5) A;
(%o5)                   [1, 1, 1, 1, 3, 5, 6, 7, 9, 9]
(%i6) ```

Help for Sort