===== PascalABC.NET =====
-1-
begin
var a := new integer[9];
for var i := 0 to 2 do
a[3 * i] := ReadInteger('Введи элемент ' + (3 * i + 1).ToString);
a[3 * i + 1] := 6 * i + 4;
a[3 * i + 2] := Random(0, 9)
end;
a.Println
end.
-2-
var a := ArrRandom(15, -99, 99);
a.Println;
var b := a.Select(p -> p * p).ToArray;
b.Println;
Println('Разность', a.Max - b.Min)
===== PascalABC.NET =====
-1-
begin
var a := new integer[9];
for var i := 0 to 2 do
begin
a[3 * i] := ReadInteger('Введи элемент ' + (3 * i + 1).ToString);
a[3 * i + 1] := 6 * i + 4;
a[3 * i + 2] := Random(0, 9)
end;
a.Println
end.
-2-
begin
var a := ArrRandom(15, -99, 99);
a.Println;
var b := a.Select(p -> p * p).ToArray;
b.Println;
Println('Разность', a.Max - b.Min)
end.