var a,b:array[1..400000000] of boolean;
     n,k,i,j,s,t:longint;

begin

readln(n,k);
for i:=1 to n do
 a[i]:=true;
for i:=1 to n*2 do
 b[i]:=false;

for i:=1 to k do begin
  read(t);
  a[t]:=false
end;
for i:=1 to n do
 if a[i]=true then
 for j:=i to n do begin
  if ((a[i])and(a[j])=true) then b[i+j]:=true;

 end;
s:=0;
for i:=1 to n*2 do
 s:=s+byte(b[i]);
write(s);

end.
