var a: array[0..6] of array [0..7] of Integer; i,j: integer; Count,Pr: integer; begin Count:=0; Pr:=1; for I := 0 to 6 do begin for J := 0 to 7 do Read(a[i,j]); Readln(); end;
for I := 0 to 6 do for J := 0 to 7 do begin if a[i,j]>0 then begin Inc(Count); Pr:=Pr*a[i,j]; end; end;
if Count=0 then Pr:=0;
Writeln('Количество чисел a[i,j]>0 = ',Count); Writeln('Произведение чисел a[i,j]>0 = ',Pr); Readln(); end.
{$APPTYPE CONSOLE}
var
a: array[0..6] of array [0..7] of Integer;
i,j: integer;
Count,Pr: integer;
begin
Count:=0;
Pr:=1;
for I := 0 to 6 do
begin
for J := 0 to 7 do
Read(a[i,j]);
Readln();
end;
for I := 0 to 6 do
for J := 0 to 7 do
begin
if a[i,j]>0 then
begin
Inc(Count);
Pr:=Pr*a[i,j];
end;
end;
if Count=0 then
Pr:=0;
Writeln('Количество чисел a[i,j]>0 = ',Count);
Writeln('Произведение чисел a[i,j]>0 = ',Pr);
Readln();
end.