N, M = list(map(int,input().split()))
A = sorted(list(map(int,input().split())), reverse=True)
b = []

b.append(A.pop(0)//2)
for i in range(1,M):
    if A == []:
        b.append(b.pop(0)//2)
    else:
        if A[0] > b[0]:
            b.append(A.pop(0)//2)
        else:
            b.append(b.pop(0)//2)

print(sum(A)+sum(b)) N, M = list(map(int,input().split())) N list(map(int,input().split())) list map(int,input().split()) map int input().split() ().split () input split M A = sorted(list(map(int,input().split())), reverse=True) A sorted(list(map(int,input().split())), reverse=True) sorted list(map(int,input().split())) list map(int,input().split()) map int input().split() ().split () input split reverse=True reverse True b = [] b [] b.append(A.pop(0)//2) b.append b append A.pop(0)//2 A.pop(0) A.pop A pop 0 2 for i in range(1,M):
    if A == []:
        b.append(b.pop(0)//2)
    else:
        if A[0] > b[0]:
            b.append(A.pop(0)//2)
        else:
            b.append(b.pop(0)//2) i range(1,M) range 1 M if A == []:
        b.append(b.pop(0)//2)
    else:
        if A[0] > b[0]:
            b.append(A.pop(0)//2)
        else:
            b.append(b.pop(0)//2) A == [] A [] b.append(b.pop(0)//2) b.append b append b.pop(0)//2 b.pop(0) b.pop b pop 0 2 if A[0] > b[0]:
            b.append(A.pop(0)//2)
        else:
            b.append(b.pop(0)//2) A[0] > b[0] A[0] A 0 b[0] b 0 b.append(A.pop(0)//2) b.append b append A.pop(0)//2 A.pop(0) A.pop A pop 0 2 b.append(b.pop(0)//2) b.append b append b.pop(0)//2 b.pop(0) b.pop b pop 0 2 print(sum(A)+sum(b)) print sum(A)+sum(b) sum(A) sum A sum(b) sum b b = [] [] b A = sorted(list(map(int,input().split())), reverse=True) sorted(list(map(int,input().split())), reverse=True) A M = list(map(int,input().split())) list(map(int,input().split())) M N, M = list(map(int,input().split())) list(map(int,input().split())) N
N, M = list(map(int,input().split()))
A = sorted(list(map(int,input().split())), reverse=True)
b = []

b.append(A.pop(0)//2)
for i in range(1,M):
    if A == []:
        b.append(b.pop(0)//2)
    else:
        if A[0] > b[0]:
            b.append(A.pop(0)//2)
        else:
            b.append(b.pop(0)//2)

print(sum(A)+sum(b))