Var i, max, min:Integer;
A:array[1..10]of integer;
Begin
Max:=-1;min:=10;
For i:=1 to 10 do begin
A[i]:=random(10);
Write(' ', a[i]) ;
If a[i]>max then max:=A[i];
If a[i]<min then min:=a[i];
End;
Writeln;
Write(max-min) ;
End.
Var i, max, min:Integer;
A:array[1..10]of integer;
Begin
Max:=-1;min:=10;
For i:=1 to 10 do begin
A[i]:=random(10);
Write(' ', a[i]) ;
If a[i]>max then max:=A[i];
If a[i]<min then min:=a[i];
End;
Writeln;
Write(max-min) ;
End.