n,m=map(int, input().split())
a=[int(x) for x in input().split()]
a=[-1*x for x in a]

import heapq

heapq.heapify(a)

for i in range(m):
    max_value = heapq.heappop(a) #最大値の取得
    heapq.heappush(a, (max_value/2)) #半額にして-1倍してからキューに戻す

a=[-1*x for x in a]
a=[int(x) for x in a]
print(sum(a)) n,m=map(int, input().split()) n map(int, input().split()) map int input().split() ().split () input split m int(x) for x in input().split() for x in input().split() x input().split() ().split () input split for x in input().split() int(x) int x a=[int(x) for x in input().split()] a [int(x) for x in input().split()] -1*x for x in a for x in a x a for x in a -1*x -1 x a=[-1*x for x in a] a [-1*x for x in a] import heapq heapq heapq.heapify(a) heapq.heapify heapq heapify a for i in range(m):
    max_value = heapq.heappop(a) #最大値の取得
    heapq.heappush(a, (max_value/2)) #半額にして-1倍してからキューに戻す i range(m) range m max_value = heapq.heappop(a) max_value heapq.heappop(a) heapq.heappop heapq heappop a heapq.heappush(a, (max_value/2)) heapq.heappush heapq heappush a max_value/2 max_value 2 -1*x for x in a for x in a x a for x in a -1*x -1 x a=[-1*x for x in a] a [-1*x for x in a] int(x) for x in a for x in a x a for x in a int(x) int x a=[int(x) for x in a] a [int(x) for x in a] print(sum(a)) print sum(a) sum a a=[-1*x for x in a] [-1*x for x in a] a a=[int(x) for x in a] [int(x) for x in a] a max_value = heapq.heappop(a) heapq.heappop(a) max_value a=[-1*x for x in a] [-1*x for x in a] a m=map(int, input().split()) map(int, input().split()) m n,m=map(int, input().split()) map(int, input().split()) n a=[int(x) for x in input().split()] [int(x) for x in input().split()] a
n,m=map(int, input().split())
a=[int(x) for x in input().split()]
a=[-1*x for x in a]

import heapq

heapq.heapify(a)

for i in range(m):
    max_value = heapq.heappop(a) #最大値の取得
    heapq.heappush(a, (max_value/2)) #半額にして-1倍してからキューに戻す

a=[-1*x for x in a]
a=[int(x) for x in a]
print(sum(a))