Var ma:array[1..n,1..n] of integer; min,mini,minj,i,j:integer; begin min:=2147483647; randomize; writeln('Matrix:'); for i:=1 to n do begin; writeln; for j:=1 to n do begin; ma[i,j]:=random(300); write(ma[i,j]:4); if min>ma[i,j] then begin; min:=ma[i,j]; mini:=i; minj:=j; end; end; end; writeln; write('Строка:',mini,' столбец:',minj); end.
Const
n=10;
Var
ma:array[1..n,1..n] of integer;
min,mini,minj,i,j:integer;
begin
min:=2147483647;
randomize;
writeln('Matrix:');
for i:=1 to n do
begin;
writeln;
for j:=1 to n do
begin;
ma[i,j]:=random(300);
write(ma[i,j]:4);
if min>ma[i,j] then
begin;
min:=ma[i,j];
mini:=i;
minj:=j;
end;
end;
end;
writeln;
write('Строка:',mini,' столбец:',minj);
end.