var
a:array [1..3,1..3] of integer;
min,i,j:integer;
begin
randomize;
for i:=1 to 3 do begin
for j:=1 to 3 do begin
a[i,j]:=random(9)+1;
write (a[i,j]:4);
end;
writeln;
min:=a[3,1];
for i:=2 to 3 do
if a[3,i]<min then min:=a[3,i];
writeln ('Min: ',min);
if (i=j) then a[i,j]:=min;
readln;
end.
var
a:array [1..3,1..3] of integer;
min,i,j:integer;
begin
randomize;
for i:=1 to 3 do begin
for j:=1 to 3 do begin
a[i,j]:=random(9)+1;
write (a[i,j]:4);
end;
writeln;
end;
min:=a[3,1];
for i:=2 to 3 do
if a[3,i]<min then min:=a[3,i];
writeln ('Min: ',min);
for i:=1 to 3 do begin
for j:=1 to 3 do begin
if (i=j) then a[i,j]:=min;
write (a[i,j]:4);
end;
writeln;
end;
readln;
end.