Var a:array[1..100,1..100] of integer; N,M,i,j,min,kmin:integer; begin readln(N,M); min:=10000; kmin:=0; for i:=1 to N do begin writeln(); for j:=1 to M do begin a[i,j]:=random(50); write(a[i,j],' '); if min = a[i,j] then kmin:=kmin+1 else if min > a[i,j] then begin kmin:=1; min:=a[i,j]; end; end; end; writeln(); write(min,' ',kmin); readln(); end.
N,M,i,j,min,kmin:integer;
begin
readln(N,M);
min:=10000;
kmin:=0;
for i:=1 to N do begin
writeln();
for j:=1 to M do begin
a[i,j]:=random(50);
write(a[i,j],' ');
if min = a[i,j] then
kmin:=kmin+1
else if min > a[i,j] then begin
kmin:=1; min:=a[i,j];
end;
end;
end;
writeln();
write(min,' ',kmin);
readln();
end.