program Array10;
var
A: array [1..10] of Integer;
i, c: Integer;
begin
Randomize;
WriteLn ('Массив:');
for i := Low (A) to High (A) do begin
A [i] := Random (10);
Write (A [i], ' ');
end;
c := 0;
if A [i] mod 2 = 0 then
Inc (c);
WriteLn;
WriteLn ('Количество четных элементов = ', c);
ReadLn;
end.
program Array10;
var
A: array [1..10] of Integer;
i, c: Integer;
begin
Randomize;
WriteLn ('Массив:');
for i := Low (A) to High (A) do begin
A [i] := Random (10);
Write (A [i], ' ');
end;
c := 0;
for i := Low (A) to High (A) do begin
if A [i] mod 2 = 0 then
Inc (c);
end;
WriteLn;
WriteLn ('Количество четных элементов = ', c);
ReadLn;
end.