program cojs126;
var
a:array[1..1000] of longint;
i,j,k,n:longint;
m:extended;
procedure qp(l,r:longint);
var
x,y,i,j:longint;
begin
i:=l; j:=r;
x:=a[(l+r) div 2];
repeat
while a[i]<x do inc(i);
while a[j]>x do dec(j);
if i<=j then
begin
y:=a[i]; a[i]:=a[j]; a[j]:=y;
inc(i); dec(j);
end;
until i>j;
if j>l then qp(l,j);
if i<r then qp(i,r);
end;
begin
assign(input,'stats.in');
assign(output,'stats.out');
reset(input);
rewrite(output);
readln(n);
m:=0;
for i:=1 to n do
begin
readln(a[i]);
m:=m+a[i];
end;
m:=m/n;
writeln(m:0:6);
qp(1,n);
if n mod 2=1 then
m:=a[n div 2+1]
else
m:=(a[n div 2+1]+a[n div 2])/2;
writeln(m:0:6);
close(input);
close(output);
end.