{$APPTYPE CONSOLE}

uses
  SysUtils;
var
  n,k,i,s,j,m:integer;
  a:array[1..1000000] of integer;
begin
  assign(input,'A.in'); reset(input);
  assign(output,'A.out'); rewrite(output);
  readln(n,k);
  for i:=1 to n do
    read(a[i]);
  for i:=1 to n-1 do
    for j:=i+1 to n do
      if a[i]>a[j] then
      begin
        m:=a[i];
        a[i]:=a[j];
        a[j]:=m;
      end;
  s:=0;
  for i:=k+1 to n do
    s:=s+a[i];
  writeln(s);
  close(input);
  close(output);
end.
 