n,m=map(int,input().split())
a=list(map(int,input().split()))
for i in range(n):
  a[i]=a[i]*-1
import heapq
heapq.heapify(a)
for i in range(m):
  t=(heapq.heappop(a))*-1
  heapq.heappush(a,(t//2)*-1)
print(sum(a)*-1) n,m=map(int,input().split()) n map(int,input().split()) map int input().split() ().split () input split m a=list(map(int,input().split())) a list(map(int,input().split())) list map(int,input().split()) map int input().split() ().split () input split for i in range(n):
  a[i]=a[i]*-1 i range(n) range n a[i]=a[i]*-1 a[i] a i a[i]*-1 a[i] a i -1 import heapq heapq heapq.heapify(a) heapq.heapify heapq heapify a for i in range(m):
  t=(heapq.heappop(a))*-1
  heapq.heappush(a,(t//2)*-1) i range(m) range m t=(heapq.heappop(a))*-1 t (heapq.heappop(a))*-1 heapq.heappop(a) heapq.heappop heapq heappop a -1 heapq.heappush(a,(t//2)*-1) heapq.heappush heapq heappush a (t//2)*-1 t//2 t 2 -1 print(sum(a)*-1) print sum(a)*-1 sum(a) sum a -1 n,m=map(int,input().split()) map(int,input().split()) n a=list(map(int,input().split())) list(map(int,input().split())) a t=(heapq.heappop(a))*-1 (heapq.heappop(a))*-1 t m=map(int,input().split()) map(int,input().split()) m
n,m=map(int,input().split())
a=list(map(int,input().split()))
for i in range(n):
  a[i]=a[i]*-1
import heapq
heapq.heapify(a)
for i in range(m):
  t=(heapq.heappop(a))*-1
  heapq.heappush(a,(t//2)*-1)
print(sum(a)*-1)