Program pr2; uses crt; var m,n,i,j,k,l:integer; mas: array[1..99,1..99] of integer; masb: array [1..99] of integer; begin clrscr; write('vvedite m'); readln(m); write('vvedite n'); readln(n); writeln('vvedite massiv MxN') ;for i:=1 to m do for j:=1 to n do begin write('mas[',i,',',j,']= '); readln(mas[i,j]); end; for i:=1 to m do begin k:=mas[i,1]; l:=mas[i,1]; for j:=1 to n do begin if k < mas[i,j] then k:=mas[i,j]; if l > mas[i,j] then l:=mas[i,j]; end; masb[i]:=k-l;
end; for i:=1 to m do begin for j:=1 to n do write(mas[i,j],' '); writeln('result = ',masb[i]); end; readln(i) end.
uses crt;
var
m,n,i,j,k,l:integer;
mas: array[1..99,1..99] of integer;
masb: array [1..99] of integer;
begin
clrscr;
write('vvedite m');
readln(m);
write('vvedite n');
readln(n);
writeln('vvedite massiv MxN')
;for i:=1 to m do
for j:=1 to n do
begin
write('mas[',i,',',j,']= ');
readln(mas[i,j]);
end;
for i:=1 to m do
begin
k:=mas[i,1];
l:=mas[i,1];
for j:=1 to n do
begin
if k < mas[i,j] then k:=mas[i,j];
if l > mas[i,j] then l:=mas[i,j];
end;
masb[i]:=k-l;
end;
for i:=1 to m do
begin
for j:=1 to n do
write(mas[i,j],' ');
writeln('result = ',masb[i]);
end;
readln(i)
end.