input = gets.chomp.split(" ").map(&:to_i)
prices = gets.chomp.split(" ").map(&:to_i)

input[1].times do
  price = prices.max
  i = prices.index(price)
  prices[i]=price/2
end
sum = 0
prices.each do |e|
  sum += e
end

puts sum