Ответ:
program v;
var a:array[1..8] of integer;
i,max,min:integer;
begin
max:=-10000;
min:=10000;
for i:=1 to 8 do
write('a[',i,'] = ');
readln(a[i]);
if a[i]>max then max:=a[i];
if a[i]<min then min:=a[i]
end;
writeln('max = ',max);
write('min = ',min)
end.
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
Ответ:
program v;
var a:array[1..8] of integer;
i,max,min:integer;
begin
max:=-10000;
min:=10000;
for i:=1 to 8 do
begin
write('a[',i,'] = ');
readln(a[i]);
if a[i]>max then max:=a[i];
if a[i]<min then min:=a[i]
end;
writeln('max = ',max);
write('min = ',min)
end.