var n,k,i,j,b:longint;
s:int64;
a:array[1..100010] of longint;
begin
    assign(input,'a.in');
    reset(input);
    assign(output,'a.out');
    rewrite(output);
    readln(n,k);
    for i:=1 to n do
    begin
      read(a[i]);
    end;
    for i:=n-1 downto 1 do
    begin
      for j:=1 to i do
      begin
          if (a[j]>a[j+1]) then
          begin
            b:=a[j];
            a[j]:=a[j+1];
            a[j+1]:=b;
          end;
      end;
    end;
    for i:=k+1 to n do
    begin
        s:=s+a[i];
    end;
    writeln(s);
    close(input);
    close(output);
end.
 