const n = 15;var a: array[1..n] of integer; i, count: integer;begin for i := 1 to n do begin a[i] := random(100); write(a[i], ' '); if(i mod 2 = 0) and (a[i] mod 2 <> 0) then inc(count); end; writeln; writeln('[', count, ']');end.
const n = 15;
var
a: array[1..n] of integer;
i, count: integer;
begin
for i := 1 to n do begin
a[i] := random(100);
write(a[i], ' ');
if(i mod 2 = 0) and (a[i] mod 2 <> 0) then inc(count);
end;
writeln;
writeln('[', count, ']');
end.