const
maxn=1000;
type
atype=array[1..maxn] of extended;
var
a:atype;
n,i,j:integer;
total,ans2:longint;
ans,temp:extended;
begin
assign(input,'stock.in'); reset(input);
assign(output,'stock.out'); rewrite(output);
fillchar(a,sizeof(a),0);
readln(n);
for i:=1 to n do
read(a[i]);
readln;
readln(total);
ans:=0; ans2:=0;
for i:=1 to n-1 do
for j:=i+1 to n do
begin
temp:=total*100 div round(100*a[i])*(a[j]-a[i]);
if temp>0 then inc(ans2);
if temp>ans then
ans:=temp;
end;
writeln(ans:0:3);
writeln(ans2/(n*(n-1)/2):0:3);
close(input); close(output);
end.