var
x: byte;
a: array [1..30] of single;
b: System.Collections.Generic.List := new System.Collections.Generic.List();
begin
for x := 1 to 30 do
begin
a[x] := random(-99, 151);
write(a[x], ' ');
end;
foreach s: single in a do
b.Add(s);
b.Sort();
writeln();
for x := 1 to 30 do
a[x] := b[x - 1];
foreach s: single in a do
write(s, ' ');
end.