program criminala;
var n,m,x,y,i:longword;
k:longint;
a:array[-1000..1000]of longword;
begin
assign(input,'criminala.in'); reset(input);
assign(output,'criminala.out'); rewrite(output);
readln(n,m);
x:=0; y:=0;
fillchar(a,sizeof(a),0);
for i:=1 to m do
begin
readln(k);
inc(a[k]);
end;
for i:=1 to n do if (a[i]>0)and(a[-i]>0) then
begin
if a[i]>a[-i]
then begin inc(x,a[i]); inc(y,a[-i]); end
else begin inc(x,a[-i]); inc(y,a[i]); end;
end;
writeln(x);
writeln(y);
close(input); close(output);
end.