php for($i=0;$i<10;$i++){ echo $c= mt_rand(0,10); }
var a:array[1..10]of integer;
i,min,max:integer;
begin
min:=10;
max:=0;
for i:=1 to 10 do a[i]:=random(11);
for i:=1 to 10 do begin
if a[i]>max then max:=a[i];
if a[i]<min then min:=a[i];
end;
writeln(min+max);
end.
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
php
for($i=0;$i<10;$i++){
echo $c= mt_rand(0,10);
}
var a:array[1..10]of integer;
i,min,max:integer;
begin
min:=10;
max:=0;
for i:=1 to 10 do a[i]:=random(11);
for i:=1 to 10 do begin
if a[i]>max then max:=a[i];
if a[i]<min then min:=a[i];
end;
writeln(min+max);
end.