1.
const n=10;
var a:array[1..n] of integer;
i: integer;
begin
for i:=1 to n do
begin
a[i]:=random(41)-20;
write (a[i],' ')
end
end.
2.
const n=20;
var a:array[1..n] of integer;
i,k: integer;
begin
for i:=1 to n do
begin
a[i]:=random(101);
if a[i] mod 2 <> 0 then k:=k+1;
write (a[i],' ')
end;
writeln;
writeln(k)
end.