![Sapyuschm](https://sproshu.net/uploads/ava/2/ava10097.jpg)
Sapyuschm
4 год назад
Написать программу нахождения наибольшего значения их пяти переменных
ОТВЕТЫ
![Polina](https://sproshu.net/uploads/ava/3/ava106.jpg)
Polina
Oct 24, 2020
var a,b,c,d,e,max:integer;
begin
readln(a,b,c,d,e);
If (a>b) and (a>c) and (a>d) and (a>e) then max:=a;
If (b>a) and (b>c) and (b>d) and (b>e) then max:=b;
If (c>a) and (c>b) and (c>d) and (c>e) then max:=c;
If (d>a) and (d>b) and (d>c) and (d>e) then max:=d;
If (e>a) and (e>b) and (e>c) and (e>d) then max:=e;
Writeln(max);
End.
begin
readln(a,b,c,d,e);
If (a>b) and (a>c) and (a>d) and (a>e) then max:=a;
If (b>a) and (b>c) and (b>d) and (b>e) then max:=b;
If (c>a) and (c>b) and (c>d) and (c>e) then max:=c;
If (d>a) and (d>b) and (d>c) and (d>e) then max:=d;
If (e>a) and (e>b) and (e>c) and (e>d) then max:=e;
Writeln(max);
End.
959
Смежные вопросы: